Part Number Hot Search : 
FG80E PSAE800 21202833 M62238FP CEB94008 S3101 21201 IW1709
Product Description
Full Text Search
 

To Download MC68307FG16 Datasheet File

  If you can't view the Datasheet, Please click here to try to view without PDF Reader .  
 
 


  Datasheet File OCR Text:
  motorola, 1994 motorola reserves the right to make changes without further notice to any products herein. motorola makes no warranty, representation or guarantee regarding the suitability of its products for any particular purpose, nor does motorola assume any liability arising out of the application or use of any product or circuit, and specifically disclaims any and all liability, including without limitation consequential or incidental damages. "typical" parameters can and do vary in different applications. all operating parameters, including "typicals" must be validated for each customer application by customer's technical experts. motorola does not convey any license under its patent rights nor the rights of others. motorola products are not designed, intended, or authorized for use as components in systems intended for surgical implant into the body, or other applications intended to support or sustain life, or for any other application in which the failure of the motorola product could create a situation where personal injury or death may occur. should buyer purchase or use motorola products for any such unintended or unauthorized application, buyer shall indemnify and hold motorola and its officers, employees, subsidiaries, affiliates, and distributors harmless against all claims, costs, damages, and expenses, and reasonable attorney fees arising out of, directly or indirectly, any claim of personal injury or death associated with such unintended or unauthorized use, even if such claim alleges that motorola was negligent regarding the design or manufacture of the part. motorola and are registered trademarks of motorola, inc. motorola, inc. is an equal opportunity/affirmative action employer. mc68307 integrated multiple-bus processor user? manual thi d t t d ith f m k 4 0 4
motorola mc68307 user? manual iii 68k fax-it documentation comments fax 512-891-8593?ocumentation comments only the motorola high-performance embedded systems technical communications depart- ment provides a fax number for you to submit any questions or comments about this docu- ment or how to order other documents. we welcome your suggestions for improving our documentation. please do not fax technical questions. please provide the part number and revision number (located in upper right-hand corner of the cover) and the title of the document. when referring to items in the manual, please ref- erence by the page number, paragraph number, figure number, table number, and line num- ber if needed. when sending a fax, please provide your name, company, fax number, and phone number including area code. applications and technical information for questions or comments pertaining to technical information, questions, and applications, please contact one of the following sales offices nearest you.
iv mc68307 user? manual motorola sales offices field applications engineering available through all sales offices united states alabama , huntsville (205) 464-6800 arizona , tempe (602) 897-5056 california , agoura hills (818) 706-1929 california , los angeles (310) 417-8848 california , irvine (714) 753-7360 california , rosevllle (916) 922-7152 california , san diego (619) 541-2163 california , sunnyvale (408) 749-0510 colorado , colorado springs (719) 599-7497 colorado , denver (303) 337-3434 connecticut , wallingford (203) 949-4100 florida , maitland (407) 628-2636 florida , pompano beach/ fort lauderdale (305) 486-9776 florida , clearwater (813) 538-7750 georgla , atlanta (404) 729-7100 idaho , boise (208) 323-9413 illinois , chicago/hoffman estates (708) 490-9500 indlana , fort wayne (219) 436-5818 indiana , indianapolis (317) 571-0400 indiana , kokomo (317) 457-6634 iowa , cedar rapids (319) 373-1328 kansas , kansas city/mission (913) 451-8555 maryland , columbia (410) 381-1570 massachusetts , marborough (508) 481-8100 massachusetts , woburn (617) 932-9700 michigan , detroit (313) 347-6800 minnesota , minnetonka (612) 932-1500 missouri , st. louis (314) 275-7380 new jersey , fairfield (201) 808-2400 new york , fairport (716) 425-4000 new york , hauppauge (516) 361-7000 new york , poughkeepsie/fishkill (914) 473-8102 north carolina , raleigh (919) 870-4355 ohio , cleveland (216) 349-3100 ohio , columbus/worthington (614) 431-8492 ohio , dayton (513) 495-6800 oklahoma , tulsa (800) 544-9496 oregon , portland (503) 641-3681 pennsylvania , colmar (215) 997-1020 philadelphia/horsham (215) 957-4100 tennessee , knoxville (615) 690-5593 texas , austin (512) 873-2000 texas , houston (800) 343-2692 texas , plano (214) 516-5100 virginia , richmond (804) 285-2100 washington , bellevue (206) 454-4160 seattle access (206) 622-9960 wisconsin , milwaukee/brookfield (414) 792-0122 canada british columbia , vancouver (604) 293-7605 ontario , toronto (416) 497-8181 ontario , ottawa (613) 226-3491 quebec , montreal (514) 731-6881 international australia , melbourne (61-3)887-0711 australia , sydney (61(2)906-3855 brazil , sao paulo 55(11)815-4200 china , beijing 86 505-2180 finland , helsinki 358-0-35161191 car phone 358(49)211501 france , paris/vanves 33(1)40 955 900 germany , langenhagen/ hanover 49(511)789911 germany , munich 49 89 92103-0 germany , nuremberg 49 911 64-3044 germany , sindelfingen 49 7031 69 910 germany , wiesbaden 49 611 761921 hong kong , kwai fong 852-4808333 tai po 852-6668333 india , bangalore (91-812)627094 israel , tel aviv 972(3)753-8222 italy , milan 39(2)82201 japan , aizu 81(241)272231 japan , atsugi 81(0462)23-0761 japan , kumagaya 81(0485)26-2600 japan , kyushu 81(092)771-4212 japan , mito 81(0292)26-2340 japan , nagoya 81(052)232-1621 japan , osaka 81(06)305-1801 japan, sendai 81(22)268-4333 japan, tachikawa 81(0425)23-6700 japan, tokyo 81(03)3440-3311 japan , yokohama 81(045)472-2751 korea , pusan 82(51)4635-035 korea , seoul 82(2)554-5188 malaysia , penang 60(4)374514 mexico , mexico city 52(5)282-2864 mexico , guadalajara 52(36)21-8977 marketing 52(36)21-9023 customer service 52(36)669-9160 netherlands , best (31)49988 612 11 puerto rico , san juan (809)793-2170 singapore (65)2945438 spain , madrid 34(1)457-8204 or 34(1)457-8254 sweden , solna 46(8)734-8800 switzerland , geneva 41(22)7991111 switzerland , zurich 41(1)730 4074 talwan , taipei 886(2)717-7089 thailand , bangkok (66-2)254-4910 united kingdom , aylesbury 44(296)395-252 full line representatives colorado , grand junction cheryl lee whltely (303) 243-9658 kansas , wichita melinda shores/kelly greiving (316) 838 0190 nevada , reno galena technology group (702) 746 0642 new mexico , albuquerque s&s technologies, lnc. (505) 298-7177 utah , salt lake city utah component sales, inc. (801) 561-5099 washington , spokane doug kenley (509) 924-2322 argentina , buenos aires argonics, s.a. (541) 343-1787 hybrid components resellers elmo semiconductor (818) 768-7400 minco technology labs inc. (512) 834-2022 semi dice inc. (310) 594-4631
motorola mc68307 user? manual v preface the mc68307 user? manual describes the programming, capabilities, and operation of the mc68307 and the mc68000 family programmer? reference manual provides instruction details for the mc68307. the organization of this manual is as follows: section 1 introduction section 2 signal description section 3 bus operation section 4 ec000 core processor section 5 system integration module section 6 dual timer module section 7 m-bus interface module section 8 serial module section 9 ieee 1149.1 test access port section 10 applications information section 11 electrical characteristics section 12 ordering information and mechanical data
motorola mc68307 user? manual vii table of contents section 1 introduction 1.1 m68300 family ............................................................................................. 1-3 1.1.1 organization ............................................................................................... 1-3 1.1.2 advantages................................................................................................. 1-3 1.2 mc68307 architecture .................................................................................. 1-4 1.2.1 ec000 core processor............................................................................... 1-4 1.2.2 system integration module (sim07) ........................................................... 1-4 1.2.2.1 external bus interface .............................................................................. 1-5 1.2.2.2 chip select and wait state generation ................................................... 1-5 1.2.2.3 system configuration and protection ....................................................... 1-5 1.2.2.4 parallel input/output ports ....................................................................... 1-5 1.2.2.5 interrupt controller.................................................................................... 1-6 1.2.3 timer module.............................................................................................. 1-6 1.2.4 uart module ............................................................................................. 1-6 1.2.5 m-bus module............................................................................................. 1-6 1.2.6 test access port......................................................................................... 1-7 section 2 signal description 2.1 bus signals ................................................................................................... 2-5 2.1.1 address bus (a23?0) ............................................................................... 2-5 2.1.1.1 address bus (a23?8) ............................................................................. 2-5 2.1.1.2 address bus (ad7?d0) .......................................................................... 2-5 2.1.2 data bus (d15?0) .................................................................................... 2-6 2.2 chip selects.................................................................................................. 2-6 2.2.1 chip select 0 (cs0 ) .................................................................................... 2-6 2.2.2 chip select 1 (cs1 ) .................................................................................... 2-6 2.2.3 chip select 2 (cs2 , cs2b , cs2c , cs2d ) ................................................. 2-6 2.2.4 chip select 3 (cs3 ) .................................................................................... 2-7 2.3 bus control signals ...................................................................................... 2-7 2.3.1 data transfer acknowledge (dtack )........................................................ 2-7 2.3.2 address strobe (as )................................................................................... 2-8 2.3.3 read/write (r/w ) ....................................................................................... 2-8 2.3.4 data strobes, upper and lower (uds , lds ) ............................................. 2-8 2.3.5 8051 address latch enable (ale) ............................................................. 2-9 2.3.6 8051-compatible bus read (rd ) ............................................................... 2-9 2.3.7 8051-compatible bus write (wr ) .............................................................. 2-9 2.3.8 bus width select for cs0 (busw0) ........................................................... 2-9 2.4 exception control signals............................................................................. 2-9 thi d t t d ith f m k 4 0 4
table of contents viii mc68307 user? manual motorola 2.4.1 reset (reset )........................................................................................... 2-9 2.4.2 power-on reset (rstin ) ......................................................................... 2-10 2.4.3 halt (halt )............................................................................................... 2-10 2.4.4 bus request (br /pa5)............................................................................. 2-10 2.4.5 bus grant (bg /pa6) ................................................................................. 2-10 2.4.6 bus grant acknowledge (bgack /pa7) .................................................. 2-10 2.5 clock signals .............................................................................................. 2-10 2.5.1 crystal oscillator (extal, xtal)............................................................. 2-10 2.5.2 clock output (clkout)........................................................................... 2-11 2.6 test signals ................................................................................................ 2-11 2.6.1 test clock (tck) ...................................................................................... 2-11 2.6.2 test mode select (tms)........................................................................... 2-11 2.6.3 test data in (tdi)..................................................................................... 2-11 2.6.4 test data out (tdo) ................................................................................ 2-11 2.7 m-bus i/o signals....................................................................................... 2-11 2.7.1 serial clock (scl/pb0) ............................................................................ 2-11 2.7.2 serial data (sda/pb1) ............................................................................. 2-12 2.8 uart i/o signals ....................................................................................... 2-12 2.8.1 transmit data (txd/pb2) ......................................................................... 2-12 2.8.2 receive data (rxd/pb3).......................................................................... 2-12 2.8.3 request-to-send (rts /pb4)................................................................... 2-12 2.8.4 clear-to-send (cts /pb5)........................................................................ 2-12 2.9 timer i/o signals ........................................................................................ 2-12 2.9.1 timer 1 input (tin1/pb6) ......................................................................... 2-12 2.9.2 timer 2 input (tin2/pb7) ......................................................................... 2-13 2.9.3 timer 1 output (tout1 /pa3)................................................................... 2-13 2.9.4 timer 2 output (tout2 /pa4)................................................................... 2-13 2.10 interrupt request inputs ............................................................................. 2-13 2.10.1 interrupt inputs (int1 ?nt8 /pb8?b15).................................................. 2-13 2.10.2 non-maskable interrupt input (irq7 ) ....................................................... 2-13 2.11 use of pullup resistors .............................................................................. 2-13 2.12 signal index ................................................................................................ 2-14 section 3 bus operation 3.1 data transfer operations ............................................................................. 3-1 3.1.1 16-bit m68000 bus operation .................................................................... 3-1 3.1.2 16-bit m68000 bus read cycle ................................................................. 3-2 3.1.3 16-bit m68000 bus write cycle.................................................................. 3-5 3.1.4 read-modify-write cycle............................................................................ 3-8 3.1.5 cpu space cycle..................................................................................... 3-11 3.1.6 8-bit m68000 dynamically-sized bus ...................................................... 3-11 3.1.7 8051-bus operation ................................................................................. 3-13 3.2 bus arbitration ............................................................................................ 3-15 3.2.1 requesting the bus .................................................................................. 3-17
table of contents motorola mc68307 user? manual ix 3.2.2 receiving the bus grant........................................................................... 3-18 3.2.3 acknowledgment of mastership (three-wire bus arbitration only) ......... 3-18 3.3 bus arbitration control................................................................................ 3-19 3.4 bus error and halt operation ..................................................................... 3-27 3.4.1 bus error operation .................................................................................. 3-27 3.4.2 retrying the bus cycle ............................................................................. 3-29 3.4.3 halt operation........................................................................................... 3-30 3.4.4 double bus fault ...................................................................................... 3-31 3.5 reset operation.......................................................................................... 3-31 3.6 asynchronous operation ............................................................................ 3-32 3.7 synchronous operation .............................................................................. 3-35 section 4 ec000 core processor 4.1 features........................................................................................................ 4-1 4.2 processing states ......................................................................................... 4-1 4.3 programming model...................................................................................... 4-2 4.3.1 data format summary ............................................................................... 4-3 4.3.2 addressing capabilities summary .............................................................. 4-3 4.3.3 notation conventions ................................................................................. 4-4 4.4 ec000 core instruction set overview .......................................................... 4-6 4.5 exception processing ................................................................................... 4-9 4.5.1 exception vectors..................................................................................... 4-12 4.6 processing of specific exceptions .............................................................. 4-12 4.6.1 reset exception........................................................................................ 4-14 4.6.2 interrupt exceptions.................................................................................. 4-14 4.6.3 uninitialized interrupt exception ............................................................... 4-15 4.6.4 spurious interrupt exception .................................................................... 4-15 4.6.5 instruction traps ....................................................................................... 4-16 4.6.6 illegal and unimplemented instructions.................................................... 4-16 4.6.7 privilege violations ................................................................................... 4-17 4.6.8 tracing...................................................................................................... 4-17 4.6.9 bus error................................................................................................... 4-18 4.6.10 address error............................................................................................ 4-18 4.6.11 multiple exceptions................................................................................... 4-19 section 5 system integration module 5.1 module operation ......................................................................................... 5-2 5.1.1 mc68307 system configuration................................................................. 5-2 5.1.1.1 module base address register operation ............................................... 5-2 5.1.1.2 system control register functions .......................................................... 5-4 5.1.1.3 system protection functions .................................................................... 5-5 5.1.2 chip select and wait-state logic ............................................................... 5-5 5.1.2.1 programmable data-bus size .................................................................. 5-6
table of contents x mc68307 user? manual motorola 5.1.2.2 peripheral chip selects ............................................................................ 5-7 5.1.2.3 8051-compatible bus chip select ........................................................... 5-8 5.1.2.4 global chip select operation (reset defaults) ........................................ 5-8 5.1.2.5 overlap in chip select ranges ................................................................ 5-8 5.1.3 external bus interface logic....................................................................... 5-9 5.1.3.1 m68000 bus interface .............................................................................. 5-9 5.1.3.2 8051-compatible bus interface .............................................................. 5-10 5.1.3.3 port a, port b general-purpose i/o ports .............................................. 5-10 5.1.4 interrupt processing ................................................................................. 5-13 5.1.4.1 interrupt controller logic ........................................................................ 5-14 5.1.4.2 interrupt vector generation .................................................................... 5-15 5.1.4.3 irq7 non-maskable interrupt ................................................................ 5-17 5.1.4.4 general-purpose interrupt inputs ........................................................... 5-17 5.1.4.5 peripheral interrupt handling ................................................................. 5-18 5.1.5 low-power sleep logic............................................................................ 5-19 5.2 programming model ................................................................................... 5-20 5.2.1 system configuration and protection registers....................................... 5-22 5.2.1.1 module base address register (mbar) ................................................ 5-22 5.2.1.2 system control register (scr).............................................................. 5-23 5.2.1.3 system status register bits description ................................................ 5-23 5.2.1.4 system control register bits description. ............................................. 5-25 5.2.2 chip select registers ............................................................................... 5-30 5.2.2.1 base registers (br3?r0).................................................................... 5-30 5.2.2.2 option registers (or3?r0) ................................................................ 5-32 5.2.3 external bus interface control registers ................................................. 5-34 5.2.3.1 port a control register (pacnt) ........................................................... 5-34 5.2.3.2 port a data direction register (paddr) ............................................... 5-35 5.2.3.3 port a data register (padat) ............................................................... 5-35 5.2.3.4 port b control register (pbcnt) ........................................................... 5-36 5.2.3.5 port b data direction register (pbddr) ............................................... 5-36 5.2.3.6 port b data register (pbdat) ............................................................... 5-37 5.2.4 interrupt control registers ....................................................................... 5-38 5.2.4.1 latched interrupt control registers 1,2 (licr1,licr2)......................... 5-38 5.2.4.2 peripheral interrupt control register (picr).......................................... 5-39 5.2.4.3 programmable interrupt vector register (pivr) .................................... 5-40 5.3 mc68307 initialization procedure............................................................... 5-41 5.3.1 startup?old reset................................................................................. 5-41 5.3.2 sim configuration..................................................................................... 5-41 section 6 dual timer module 6.1 overview....................................................................................................... 6-1 6.2 module operation ......................................................................................... 6-1 6.2.1 general-purpose timer units..................................................................... 6-1 6.2.2 software watchdog timer .......................................................................... 6-3
table of contents motorola mc68307 user? manual xi 6.3 programming model...................................................................................... 6-4 6.3.1 general purpose timer units ..................................................................... 6-4 6.3.1.1 timer mode register (tmr1, tmr2) ....................................................... 6-4 6.3.1.2 timer reference registers (trr1, trr2)............................................... 6-5 6.3.1.3 timer capture registers (tcr1, tcr2) .................................................. 6-5 6.3.1.4 timer counter (tcn1, tcn2)................................................................... 6-5 6.3.1.5 timer event registers (ter1, ter2) ...................................................... 6-6 6.3.2 software watchdog timer .......................................................................... 6-7 6.3.2.1 watchdog reference register (wrr)...................................................... 6-7 6.3.2.2 watchdog counter register (wcr) ......................................................... 6-7 6.4 timer programming examples ..................................................................... 6-8 6.4.1 initialization and reference compare function.......................................... 6-8 6.4.2 event counting function and interrupts ..................................................... 6-9 6.4.3 input capture function ............................................................................... 6-9 6.4.4 watchdog usage example ....................................................................... 6-10 section 7 m-bus interface module 7.1 m-bus system configuration ........................................................................ 7-2 7.2 m-bus protocol ............................................................................................. 7-2 7.2.1 start signal ............................................................................................. 7-3 7.2.2 slave address transmission ...................................................................... 7-3 7.2.3 data transfer .............................................................................................. 7-3 7.2.4 repeated start signal ............................................................................ 7-4 7.2.5 stop signal ............................................................................................... 7-4 7.2.6 arbitration procedure.................................................................................. 7-4 7.2.7 clock synchronization ................................................................................ 7-4 7.2.8 handshaking............................................................................................... 7-5 7.2.9 clock stretching.......................................................................................... 7-5 7.3 programming model...................................................................................... 7-5 7.3.1 m-bus address register (madr) ............................................................... 7-6 7.3.2 m-bus frequency divider register (mfdr) ............................................... 7-6 7.3.3 m-bus control register (mbcr) ................................................................ 7-7 7.3.4 m-bus status register (mbsr) .................................................................. 7-9 7.3.5 m-bus data i/o register (mbdr)............................................................. 7-10 7.4 m-bus programming examples .................................................................. 7-10 7.4.1 initialization sequence.............................................................................. 7-10 7.4.2 generation of start ............................................................................... 7-11 7.4.3 post-transfer software response............................................................ 7-11 7.4.4 generation of stop ................................................................................. 7-12 7.4.5 generation of repeated start............................................................... 7-13 7.4.6 slave mode............................................................................................... 7-13 7.4.7 arbitration lost.......................................................................................... 7-13
table of contents xii mc68307 user? manual motorola section 8 serial module 8.1 module overview .......................................................................................... 8-2 8.1.1 serial communication channel .................................................................. 8-2 8.1.2 baud rate generator logic........................................................................ 8-3 8.1.3 baud rate generator/timer ....................................................................... 8-3 8.1.4 interrupt control logic ................................................................................ 8-3 8.1.5 comparison of serial module to mc68681................................................. 8-3 8.2 serial module signal definitions ................................................................... 8-3 8.2.1 transmitter serial data output (txd) ......................................................... 8-4 8.2.2 receiver serial data input (rxd) ............................................................... 8-4 8.2.3 request-to-send (rts )............................................................................. 8-4 8.2.4 clear-to-send (cts ) ................................................................................. 8-5 8.3 operation ...................................................................................................... 8-5 8.3.1 baud rate generator/timer ....................................................................... 8-5 8.3.2 transmitter and receiver operating modes............................................... 8-5 8.3.2.1 transmitter ............................................................................................... 8-6 8.3.2.2 receiver ................................................................................................... 8-8 8.3.2.3 fifo stack ............................................................................................... 8-8 8.3.3 looping modes ......................................................................................... 8-10 8.3.3.1 automatic echo mode ............................................................................ 8-10 8.3.3.2 local loopback mode ............................................................................ 8-11 8.3.3.3 remote loopback mode ........................................................................ 8-11 8.3.4 multidrop mode......................................................................................... 8-12 8.3.5 bus operation........................................................................................... 8-14 8.3.5.1 read cycles ........................................................................................... 8-14 8.3.5.2 write cycles ........................................................................................... 8-14 8.3.5.3 interrupt acknowledge cycles ................................................................ 8-14 8.4 register description and programming...................................................... 8-14 8.4.1 register description ................................................................................. 8-14 8.4.1.1 mode register 1 (umr1) ....................................................................... 8-15 8.4.1.2 mode register 2 (umr2) ....................................................................... 8-17 8.4.1.3 status register (usr) ............................................................................ 8-19 8.4.1.4 clock-select register (ucsr) ................................................................ 8-21 8.4.1.5 command register (ucr) ..................................................................... 8-23 8.4.1.6 receiver buffer (urb)............................................................................ 8-25 8.4.1.7 transmitter buffer (utb) ........................................................................ 8-25 8.4.1.8 input port change register (uipcr) ..................................................... 8-26 8.4.1.9 auxiliary control register (uacr) ......................................................... 8-26 8.4.1.10 interrupt status register (uisr) ............................................................ 8-27 8.4.1.11 interrupt mask register (uimr).............................................................. 8-28 8.4.1.12 timer upper preload register (ubg1)................................................... 8-29 8.4.1.13 timer upper preload register (ubg2)................................................... 8-29 8.4.1.14 interrupt vector register (uivr) ............................................................ 8-29 8.4.1.15 input port register (uip) ........................................................................ 8-29
table of contents motorola mc68307 user? manual xiii 8.4.1.16 output port data registers (uop1, uop0)............................................ 8-30 8.4.2 programming ............................................................................................ 8-30 8.4.2.1 serial module initialization ...................................................................... 8-31 8.4.2.2 i/o driver example ................................................................................. 8-31 8.4.2.3 interrupt handling ................................................................................... 8-31 8.5 serial module initialization sequence ......................................................... 8-31 section 9 ieee 1149.1 test access port 9.1 overview ....................................................................................................... 9-1 9.2 tap controller ............................................................................................... 9-3 9.3 boundary scan register ............................................................................... 9-4 9.4 instruction register ....................................................................................... 9-9 9.4.1 extest (0000) ........................................................................................ 9-10 9.4.2 sample/preload (0010)...................................................................... 9-10 9.4.3 bypass (1111) ........................................................................................ 9-10 9.4.4 clamp (1100) .......................................................................................... 9-11 9.5 mc68307 restrictions................................................................................. 9-11 9.6 non-ieee 1149.1 operation ....................................................................... 9-11 section 10 applications information 10.1 mc68307 minimum stand-alone system hardware .................................. 10-1 10.1.1 mc68307 signal configuration................................................................. 10-1 10.1.2 eprom memory interface........................................................................ 10-5 10.1.3 ram memory interface ............................................................................. 10-5 10.1.4 rs232 uart port .................................................................................... 10-5 10.1.5 eprom timing ......................................................................................... 10-6 10.1.6 ram timing .............................................................................................. 10-6 10.2 power management.................................................................................... 10-7 10.2.1 fully static operation ............................................................................... 10-7 10.2.2 prescalable cpu clock ............................................................................ 10-8 10.2.3 wake-up ................................................................................................... 10-8 10.2.4 low-power sleep mode............................................................................ 10-9 10.2.5 low-power stop mode ............................................................................. 10-9 10.3 using m-bus software to communicate between processor systems .... 10-10 10.3.1 overview of m-bus software transfer mechanism ................................ 10-11 10.3.2 m-bus master mode operation............................................................... 10-12 10.3.3 m-bus slave mode operation................................................................. 10-12 10.3.4 description of setup ............................................................................... 10-13 10.3.5 software flow ......................................................................................... 10-13 10.3.6 transfer blocks ....................................................................................... 10-14 10.3.7 software implementation ........................................................................ 10-14 10.3.7.1 software listing 1?-bus master software ........................................ 10-17 10.3.7.2 software listing 2?-bus slave software .......................................... 10-21
table of contents xiv mc68307 user? manual motorola 10.4 mc68307 uart driver examples ............................................................ 10-24 10.4.1 software listing 3 ................................................................................... 10-24 10.5 swapping rom and ram mapping on the mc68307 .............................. 10-27 10.5.1 software implementation........................................................................ 10-27 10.5.1.1 software listing 4 ................................................................................. 10-28 section 11 electrical characteristics 11.1 maximum ratings ....................................................................................... 11-1 11.2 thermal characteristics.............................................................................. 11-1 11.3 power considerations................................................................................. 11-2 11.4 ac electrical specification definitions ........................................................ 11-2 11.5 dc electrical specifications........................................................................ 11-4 11.6 ac electrical specifications?lock timing................................................ 11-4 11.7 ac electrical specifications?ead and write cycles................................ 11-5 11.8 ac electrical specifications?us arbitration............................................. 11-9 11.9 ac electrical specifications?051 bus interface module ....................... 11-11 11.10 timer module electrical characteristics ................................................... 11-13 11.11 uart electrical characteristics................................................................ 11-14 11.12 ac electrical characteristics?-bus input signal timing....................... 11-15 11.13 ac electrical characteristics?-bus output signal timing.................... 11-15 11.14 ac electrical characteristics?ort timing .............................................. 11-16 11.15 ieee 1149.1 electrical characteristics ..................................................... 11-17 section 12 ordering information and mechanical data 12.1 standard ordering information ................................................................... 12-1 12.2 100-pin pqfp pin assignments................................................................. 12-1 12.3 100-pin pqfp package dimensions.......................................................... 12-2 12.4 100-pin tqfp pin assignments ................................................................. 12-3 12.5 100-pin tqfp package dimensions .......................................................... 12-4 index
motorola mc68307 user? manual xv list of illustrations 1-1 mc68307 block diagram ................................................................................... 1-1 2-1 mc68307 detailed block diagram ..................................................................... 2-2 3-1 word read cycle flowchart (16-bit bus)........................................................... 3-2 3-2 byte read cycle flowchart (16-bit bus) ............................................................ 3-3 3-3 read and write cycle timing diagram (16-bit bus) .......................................... 3-3 3-4 word and byte read cycle timing diagram (16-bit bus).................................. 3-4 3-5 word write cycle flowchart (16-bit bus)........................................................... 3-5 3-6 byte write cycle flowchart (16-bit bus) ............................................................ 3-6 3-7 word and byte write cycle timing diagram...................................................... 3-6 3-8 read-modify-write cycle flowchart................................................................... 3-8 3-9 read-modify-write cycle timing diagram ......................................................... 3-9 3-10 interrupt acknowledge cycle ?address bus ................................................... 3-11 3-11 interrupt acknowledge cycle timing diagram ................................................. 3-12 3-12 8051-compatible read cycle signals.............................................................. 3-14 3-13 8051-compatible write cycle signals.............................................................. 3-14 3-14 three-wire bus arbitration cycle flowchart .................................................... 3-15 3-15 two-wire bus arbitration cycle flowchart....................................................... 3-16 3-16 three-wire bus arbitration timing diagram .................................................... 3-17 3-17 two-wire bus arbitration timing diagram ....................................................... 3-17 3-18 external asynchronous signal synchronization............................................... 3-19 3-19 bus arbitration unit state diagrams................................................................. 3-20 3-20 three-wire bus arbitration timing diagram?rocessor active...................... 3-21 3-21 three-wire bus arbitration timing diagram?us inactive ............................. 3-22 3-22 three-wire bus arbitration timing diagram?pecial case............................ 3-23 3-23 two-wire bus arbitration timing diagram?rocessor active ........................ 3-24 3-24 two-wire bus arbitration timing diagram?us inactive................................ 3-25 3-25 two-wire bus arbitration timing diagram?pecial case .............................. 3-26 3-26 bus error timing diagram................................................................................ 3-28 3-27 retry bus cycle timing diagram ..................................................................... 3-29 3-28 halt operation timing diagram........................................................................ 3-30 3-29 reset operation timing diagram..................................................................... 3-32 3-30 fully asynchronous read cycle ...................................................................... 3-33 3-31 fully asynchronous write cycle....................................................................... 3-33 3-32 pseudo-asynchronous write cycle.................................................................. 3-34 3-33 pseudo-asynchronous read cycle.................................................................. 3-34 3-34 synchronous read cycle................................................................................. 3-37 3-35 synchronous write cycle ................................................................................. 3-37 4-1 programming model ........................................................................................... 4-2 4-2 status register................................................................................................... 4-3 thi d t t d ith f m k 4 0 4
list of illustrations xvi mc68307 user? manual motorola 4-3 general form of exception stack frame......................................................... 4-10 4-4 general exception processing flowchart ........................................................ 4-11 4-5 exception vector format.................................................................................. 4-12 4-6 address translated from 8-bit vector number ................................................ 4-12 4-7 supervisor stack order for bus or address error exception ........................... 4-19 5-1 module base address, decode logic ................................................................ 5-3 5-2 chip-select block diagram ................................................................................ 5-6 5-3 external bus interface logic .............................................................................. 5-9 5-4 interrupt controller logic block diagram ......................................................... 5-15 6-1 timer block diagram.......................................................................................... 6-2 7-1 m-bus interface block diagram ......................................................................... 7-2 7-2 m-bus transmission signals.............................................................................. 7-3 7-3 m-bus clock synchronization ............................................................................ 7-5 7-4 flow-chart of typical m-bus interrupt routine ................................................ 7-14 8-1 simplified block diagram ................................................................................... 8-1 8-2 external and internal interface signals .............................................................. 8-4 8-3 baud rate generator block diagram................................................................. 8-5 8-4 transmitter and receiver functional diagram................................................... 8-6 8-5 transmitter timing diagram............................................................................... 8-7 8-6 receiver timing diagram................................................................................... 8-9 8-7 looping modes functional diagram ................................................................ 8-11 8-8 multidrop mode timing diagram ...................................................................... 8-13 8-9 serial mode programming flowchart............................................................... 8-32 9-1 test access port block diagram........................................................................ 9-2 9-2 tap controller state machine............................................................................ 9-3 9-3 output cell (o.cell)............................................................................................ 9-6 9-4 input cell (i.cell) ................................................................................................ 9-7 9-5 output control cell (en.cell).............................................................................. 9-7 9-6 bidirectional cell (io.cell) .................................................................................. 9-8 9-7 bidirectional cell (iox0.cell) .............................................................................. 9-8 9-8 general arrangement for bidirectional pins....................................................... 9-9 9-9 bypass register ............................................................................................... 9-10 10-1 mc68307 minimum system configuration....................................................... 10-3 10-2 hardware setup ............................................................................................. 10-13 10-3 master/slave responsibilities for the master transmit block ........................ 10-15 10-4 summary of m-bus activity for the master transmit block ............................ 10-15 10-5 master/slave responsibilities for the master receive block ......................... 10-16 10-6 summary of m-bus activity for the master receive block ............................. 10-16 10-7 memory map after swap complete................................................................ 10-28 11-1 drive levels and test points for ac specifications ......................................... 11-3 11-2 clock timing .................................................................................................... 11-5 11-3 read cycle timing diagram ............................................................................ 11-7 11-4 write cycle timing diagram ............................................................................ 11-8 11-5 three-wire bus arbitration diagram ................................................................ 11-9 11-6 two-wire bus arbitration timing diagram..................................................... 11-10
list of illustrations motorola mc68307 user? manual xvii 11-7 external 8051 bus read cycle ...................................................................... 11-12 11-8 external 8051 bus write cycle....................................................................... 11-12 11-9 timer module timing diagram ....................................................................... 11-13 11-10 transmitter timing ......................................................................................... 11-14 11-11 receiver timing ............................................................................................. 11-14 11-12 m-bus interface input/output signal timing .................................................. 11-15 11-13 port timing ..................................................................................................... 11-16 11-14 test clock input timing diagram ................................................................... 11-17 11-15 boundary scan timing diagram .................................................................... 11-18 11-16 test access port timing diagram.................................................................. 11-18
motorola mc68307 user? manual xix list of tables 2-1 68000 bus signal summary............................................................................... 2-3 2-2 8051 bus signal summary................................................................................. 2-3 2-3 chip select signal summary.............................................................................. 2-3 2-4 interrupt port signal summary ........................................................................... 2-4 2-5 clock and mode control signal summary ......................................................... 2-4 2-6 serial module signal summary .......................................................................... 2-4 2-7 jtag signal summary....................................................................................... 2-4 2-8 timer module signal summary .......................................................................... 2-5 2-9 m-bus module signal summary......................................................................... 2-5 2-10 data strobe control of data bus........................................................................ 2-8 2-11 signal index...................................................................................................... 2-14 4-1 processor data formats .................................................................................... 4-3 4-2 effective addressing modes............................................................................... 4-4 4-3 notation conventions ......................................................................................... 4-4 4-4 ec000 core instruction set summary ............................................................... 4-6 4-5 exception vector assignments......................................................................... 4-13 4-6 exception grouping and priority....................................................................... 4-19 5-1 address block selection in peripheral chip select mode .................................. 5-7 5-2 port a pin functions......................................................................................... 5-12 5-3 port b pin functions......................................................................................... 5-12 5-4 interrupt vector response ............................................................................... 5-16 5-5 mc68307 configuration memory map ............................................................. 5-20 5-6 dtack field encoding .................................................................................... 5-32 7-1 m-bus prescaler values..................................................................................... 7-7 8-1 serial module programming model .................................................................. 8-15 8-2 pmx and pt control bits .................................................................................. 8-16 8-3 b/cx control bits .............................................................................................. 8-17 8-4 cmx control bits .............................................................................................. 8-17 8-5 sbx control bits ............................................................................................... 8-18 8-6 rcsx control bits ............................................................................................ 8-21 8-7 tcsx control bits............................................................................................. 8-22 8-8 miscx control bits ........................................................................................... 8-23 8-9 tcx control bits ............................................................................................... 8-24 8-10 rcx control bits............................................................................................... 8-24 8-11 timer mode and source select bits................................................................. 8-27 9-1 boundary scan control bits ............................................................................... 9-4 9-2 boundary scan bit definitions............................................................................ 9-5 9-3 instructions ......................................................................................................... 9-9 10-1 power contribution from modules .................................................................... 10-7 thi d t t d ith f m k 4 0 4
motorola mc68307 user? manual 1-1 section 1 introduction the mc68307 is an integrated processor combining a static ec000 processor with multiple interchip bus interfaces. the mc68307 is designed to provide optimal integration and performance for applications such as digital cordless telephones, portable measuring equipment, and point-of-sale terminals. by providing 3.3 v, static operation in a small package, the mc68307 delivers cost-effective performance to handheld, battery-powered applications. the mc68307 (see figure 1-1) contains a static ec000 core processor, multiple bus interfaces, a serial channel, two timers, and common system glue logic. the multiple bus interfaces include: dynamic 68000 bus, 8051-compatible bus, and motorola bus (m-bus) or i 2 c bus 1 . the dynamically-sized 68000 bus allows 16-bit performance using static random access memory (sram) while providing a low-cost interface to an 8-bit read-only memory (rom). the 8051-compatible bus interfaces gluelessly to 8051-type devices and allows the reuse 1. i 2 c bus is a proprietary philips interface bus. figure 1-1. mc68307 block diagram processor control and clock 68000 internal bus 8/16-bit m68000 bus interface interrupt controller dual timer module uart serial i/o m-bus module static ec000 core processor dynamic bus sizing extension system integration module (sim07) 8051 bus interface chip select and dtack parallel i/o ports system protection power management jtag port thi d t t d ith f m k 4 0 4
introduction 1-2 mc68307 user? manual motorola of application-specific integrated circuits (asics) designed for this industry standard bus. the m-bus is an industry-standard 2-wire interface that provides efficient communications with peripherals such as eeprom, analog/digital (a/d) converters, and liquid crystal display (lcd) drivers. thus, the mc68307 interfaces gluelessly to boot rom, sram, 8051 devices, m-bus devices, and memory-mapped peripherals. the mc68307 also incorporates a slave mode which allows the ec000 core to be disabled, providing a 3.3-v or 5-v static, low-power multifunction peripheral for higher performance m68000 family processors. the main features of the mc68307 include: static ec000 core processor full compatibility with m68000 and ec000 24-bit address bus, for 16-mbyte off-chip address space 16-bit on-chip data bus for m68000 bus operations 2.7 mips performance at 16.67 mhz processor clock processor disable mmode for use as a peripheral to an external processor emulation mode for use with in-circuit emulator external m68000 bus interface with dynamic bus sizing for 8-bit and 16-bit data ports external 8051-compatible 8-bit data bus interface power management fully static operation with processor shutdown and wake-up modes for substatial power savings very rapid response to interrupts from the power-down state operates from dc to 16.67 mhz system clock clock enable/disable for each peripheral m-bus module provides interchip bus interface for eeproms, lcd controllers, a/d converters, etc. compatible with industry-standard i 2 c bus master or slave operation modes, supports multiple masters automatic interrupt generation with programmable level software-programmable clock frequency data rates from 4?00 kbit/s above 3.0 mhz system clock universal asynchronous receiver/transmitter (uart) module flexible baud rate generator based on mc68681 dual universal asynchronous receiver/transmitter (duart) programming model 5 mbits/s maximum transfer rate at 16.67 mhz system clock automatic interrupt generation with programmable level modem control signals available (cts , rts ) timer module dual channel 16-bit general-purpose counter/timer multimode operation, independent capture/compare registers automatic interrupt generation with programmable level 60-ns resolution at 16.67 mhz system clock separate input and output pins for each timer
introduction motorola mc68307 user? manual 1-3 system integration module (sim07), incorporating many functions typically relegated to external programmable array logic (pals), transistor-transistor logic (ttl), and asics, such as: ?ystem configuration, programmable address mapping ?ystem protection by hardware watchdog logic and software watchdog timer ?ower-down mode control, programmable processor clock driver ?our programmable chip selects with wait state generation logic ?hree simple peripheral chip selects ?arallel input/output ports, some with interrupt capability ?rogrammed interrupt vector response for on-chip peripheral modules ?eee 1149.1 boundary scan test access port (jtag) operating voltages of 3.3v 0.3v and 5v 0.5v 0 to 70 c (standard part); ?0 to +85 c (extended temperature part) compact 100-lead quad flat pack (qfp) and 100-lead thin quad flat pack (tqfp) packages 1.1 m68300 family the mc68307 is one of a series of components in motorola's m68300 family. other mem- bers of the family include the mc68302, mc68306, mc68322, mc68330, mc68331, mc68332, mc68f333, mc68334, mc68340, mc68341, mc68349, mc68356, and mc68360. 1.1.1 organization the m68300 family of integrated processors and controllers is built on an m68000 core pro- cessor and a selection of intelligent peripherals appropriate for a set of applications. com- mon system glue logic such as address decoding, wait state insertion, interrupt prioritization, and watchdog timing is also included. each member of the m68300 family is distinguished by its selection of on-chip peripherals. peripherals are chosen to address specific applications, but are often useful in a wide variety of applications. the peripherals may be highly sophisticated timing or protocol engines that have their own processors, or they may be more traditional peripheral functions, such as uarts and timers. 1.1.2 advantages by incorporating so many major features into a single m68300 family chip, a system designer can realize significant savings in design time, power consumption, cost, board space, pin count, and programming. the equivalent functionality can easily require 20 sep- arate components. each component might have 16?4 pins, totalling over 350 connections. most of these connections require interconnects or are duplications. each connection is a candidate for a bad solder joint or misrouted trace. each component is another part to qual- ify, purchase, inventory, and maintain. each component requires a share of the printed cir- cuit board. each component draws power, which is often used to drive large buffers to get the signal to another chip. the cumulative power consumption of all the components must be available from the power supply. the signals between the central processing unit (cpu)
introduction 1-4 mc68307 user? manual motorola and a peripheral might not be compatible nor run from the same clock, requiring time delays or other special design considerations. in an m68300 family component, the major functions and glue logic are all properly con- nected internally, timed with the same clock, fully tested, and uniformly documented. only essential signals are brought out to pins. the primary package is the surface-mount plastic qfp for the smallest possible footprint. 1.2 mc68307 architecture to improve total system throughput and reduce part count, board size and cost of system implementation, the mc68307 integrates a powerful processor, intelligent peripheral mod- ules, and typical system interface logic. these functions include the sim07, timers, uart, m-bus interface, and 8051-compatible bus interface. the ec000 core processor communicates with these modules via an internal bus, providing the opportunity for fully synchronized communication between all modules and allowing interrupts to be handled in parallel with data transfers, greatly improving system perfor- mance. 1.2.1 ec000 core processor the ec000 is a core implementation of the m68000 32-bit microprocessor architecture. the programmer can use any of the eight 32-bit data registers for fast manipulation of data and any of the eight 32-bit address registers for indexing data in memory. flexible instructions support data movement, arithmetic functions, logical operations, shifts and rotates, bit set and clear, conditional and unconditional program branches, and overall system control. the ec000 core can operate on data types of single bits, binary-coded decimal (bcd) digits, and 8, 16, and 32 bits. the integrated chip selects allow peripherals and data in memory to reside anywhere in the 16-mbyte linear address space. a supervisor operating mode pro- tects system-level resources from the more restricted user mode, allowing a true virtual envi- ronment to be developed. many addressing modes complement these instructions, including predecrement and postincrement, which allow simple stack and queue mainte- nance and scaled indexing for efficient table accesses. data types and addressing modes are supported orthogonally by all data operations and with all appropriate addressing modes. position-independent code is easily written. like all m68000 family processors, the ec000 core recognizes interrupts of seven different priority levels and, in conjunction with the integrated interrupt controller, allows a pro- grammed vector to direct the processor to the desired service routine. internal trap excep- tions ensure proper instruction execution with good addresses and data, allow operating system intervention in special situations, and permit instruction tracing. the hardware time- out can terminate bad memory accesses before instructions process data incorrectly. the ec000 core provides 2.7 millions of bits per second (mips) at 16.67 mhz. 1.2.2 system integration module (sim07) the sim07 provides the external bus interface for the ec000 core. it also eliminates much of the glue logic that typically supports a microprocessor and its interface with the peripheral
introduction motorola mc68307 user? manual 1-5 and memory system. the sim07 provides programmable circuits to perform address-decod- ing and chip selects, wait-state insertion, interrupt handling, clock generation, discrete i/o, and power management features. 1.2.2.1 external bus interface. the external bus interface (ebi) handles the trans- fer of information between the internal ec000 core and memory, peripherals, or other pro- cessing elements in the external address space. it consists of an m68000 bus interface and an 8051-compatible bus interface. the external m68000 bus provides up to 24 address lines and 16 data lines. each bus access can appear externally either as an m68000 bus cycle (either 16-bit or 8-bit dynamic data bus width) or an 8-bit wide 8051-compatible bus cycle (multiplexing address and 8-bit data) with the respective sets of control signals. the default bus cycle is an m68000 16-bit-wide one, the 8051-compatible address space being pro- grammable. 1.2.2.2 chip select and wait state generation. four programmable chip select outputs provide signals to enable external memory and peripheral circuits, providing all handshaking and timing signals for automatic wait-state insertion and data bus sizing. base memory address and block size are both programmable, with some restrictions, (e.g. a starting address must be on a boundary which is a multiple of the block size). each chip- select is general-purpose. however one of the chip-selects can be programmed to select an addressing range which is decoded as an 8051-compatible bus access, and another can be used to enable one of four simple external peripherals. data bus width (8-bit or 16-bit) is pro- grammable on all four chip-selects and further decoding is available for protection from user mode access or read-only access. 1.2.2.3 system configuration and protection. the sim07 provides configura- tion registers that allow general system functions to be controlled and monitored. for exam- ple, all on-chip registers can be relocated as a block by programming a module base address, power-down modes can be selected, and the source of the most recent reset or berr can be checked. the hardware watchdog features can be enabled or disabled and the bus timeout times can be programmed. the power-down mode allows software to disable the ec000 core during periods of inactiv- ity. this feature works in conjunction with the interrupt control logic to allow any interrupt condition to cause a wake-up, which causes the ec000 core to resume processing without requiring any reset or re-initialization. all register contents are preserved, and the inter- rupt which caused wake-up is serviced in the normal manner as soon as the clock restarts. to reduce power consumption further, the internal clocks to the on-chip peripheral modules can be disabled by software. 1.2.2.4 parallel input/output ports. two general-purpose ports (a and b) are provided for input/output, although the pins for these ports are shared with other functions. some bits in port a are multiplexed with the peripheral chip-select lines and timer output sig- nals, and port b is multiplexed with various peripheral i/o lines from the uart, m-bus and timer modules. maximum flexibility is therefore available for differing hardware configura- tions. eight of the 16 port b lines are also latched inputs to the interrupt controller, with pro- grammable interrupt priority level.
introduction 1-6 mc68307 user? manual motorola 1.2.2.5 interrupt controller. the sim07 coordinates all interrupt sources, both from on-chip peripherals (timer1, timer2, m-bus, and uart) and off-chip inputs (irq7 , and int1 ?nt8 ). it provides interrupt requests to the ec000 core with programmable priority level, and responds to acknowledge cycles by providing programmed vectors unique to each source. 1.2.3 timer module the timer module comprises two independent, identical general-purpose timers, and a soft- ware watchdog timer. each general-purpose timer block contains a free-running 16-bit timer that can be used in various modes, to capture the timer value with an external event, to trig- ger an external event or interrupt when the timer reaches a set value, or to count external events. each has an 8-bit prescaler to allow a programmable clock input frequency derived from the system clock or external count input. the output pins (one per timer) have a pro- grammable mode. a software watchdog timer is also provided for system protection. if required, this resets the ec000 core if it is not refreshed periodically by software. 1.2.4 uart module the mc68307 contains a full-duplex uart module, with an on-chip baud-generator provid- ing both standard and nonstandard baud rates up to 5 mb/s. the module is functionally equivalent to the mc68681 duart, although only one serial channel is implemented. data formats can be 5, 6, 7, or 8 bits with even, odd, or no parity and up to two stop bits in 1/16 increments. four-byte receive buffers and two-byte transmit buffers minimize cpu service calls. a wide variety of error detection and maskable interrupt capability is provided on each channel. full-duplex autoecho loopback, local loopback, and remote loopback modes can be selected. multidrop applications are supported. clocking is provided by the mc68307 system clock, via a programmable prescaler allowing various baud rates to be chosen. modem support is provided with request-to-send (rts ) and clear-to-send (cts ) lines available. the serial port can sustain data rates of 5 mbps. 1.2.5 m-bus module the m-bus interface module provides a two-wire, bidirectional serial bus which provides a simple, efficient way for data exchange between devices. it is compatible with the i 2 c-bus standard. m-bus minimizes the interconnection between devices in the end-system. it is best suited for applications which need occasional bursts of fast communication over a short distance, among a number of devices. the maximum data rate is limited to 595 kbps at 16.67 mhz (100 kbps to be compatible with i 2 c), the maximum communication length and number of devices which can be connected are limited physically by the maximum bus capacitance and logically by the number of unique addresses. the m-bus system is a true multimaster bus including collision detection and arbitration to prevent data corruption if two or more masters intend to control the bus simultaneously. this feature provides the capability for complex applications with multiprocessor control. it may also be used for rapid testing and alignment of end products via external diagnostic connec- tions.
introduction motorola mc68307 user? manual 1-7 1.2.6 test access port to aid in system diagnostics, the mc68307 includes dedicated user-accessible test logic that is compliant with the ieee 1149.1 standard for boundary scan testability, often referred to as jtag (joint test action group). this is described briefly in section 9 ieee 1149.1 test access port . for further information refer to the ieee 1149.1 standard.
motorola mc68307 user? manual 2-1 section 2 signal description this section contains a brief description of the input and output signals, with reference (if applicable) to other sections which give greater detail on its use. figure 2-1 provides a detailed diagram showing the integrated peripherals and signals, and table 2-2 to table 2- 9 provide a quick reference for determining a signal's name, mnemonic, its use as an input or output, active state, and type identification. note the terms assertion and negation will be used extensively. this is done to avoid confusion when dealing with a mixture of ?ctive-low?and ?ctive-high?signals. the term assert or asser- tion is used to indicate that a signal is active or true, independent of whether that level is represented by a high or low voltage. the term negate or negation is used to indicate that a signal is inac- tive or false. thi d t t d ith f m k 4 0 4
signal description 2-2 mc68307 user? manual motorola . figure 2-1. mc68307 detailed block diagram 16-bit 68000 internal bus tdo tdi tms tck cs2b /pa0 multiplexed parallel i/o multiplexed parallel i/o system integration module (sim07) 8-/16-bit 68000 bus interface 8051 bus interface chip and dtack processor control, clock and low power m-bus (i2c) module uart serial i/o dual timer module static ec000 core processor dynamic bus sizing extension vcc gnd 6 6 extal xtal clkout scl/pb0 sda/pb1 cts /pb5 rts /pb4 rxd/pb3 txd/pb2 tin1/pb6 tin2/pb7 cs2c /pa1 cs2d /pa2 tout1 /pa3 tout2 /pa4 br /pa5 bg /pa6 bgack /pa7 as uds lds r/w dtack d15?0 a23?8 ad7?d0 /a7?0 rd wr ale cs3 cs2 /cs2a cs1 cs0 busw0 irq7 reset halt rstin int1 /pb8 int2 /pb9 int3 /pb10 int4 /pb11 int5 /pb12 int6 /pb13 int7 /pb14 int8 /pb15 jtag port select interrupt controller
signal description motorola mc68307 user? manual 2-3 table 2-1. 68000 bus signal summary signal name mnemonic input/ output three-state during bus arbitration pullup resistor required address signals a23?0 output yes (4) address strobe as output yes (3) bus grant bg /pa6 output (2) no bus grant acknowledge bgack /pa7 input (2) (1) bus request br /pa5 input (2) (1) data bus d15?0 i/o yes data transfer acknowledge dtack i/o yes 2.2 k w halt halt i/o 2.2 k w lower data strobe lds output yes (3) upper data strobe uds output yes (3) read/write r/w output yes (3) reset reset i/o 2.2 k w table 2-2. 8051 bus signal summary signal name mnemonic input/ output three-state during bus arbitration pullup resistor required address/data bus ad7?d0 i/o yes address latch enable ale output no 8051 read strobe rd output no 8051 write strobe wr output no notes: 1. pullup may be required (value depends on individual application). this pin must not be left ?ating. 2. these signals have dual functions as port a i/o lines. their function is programmed in the port a control register. 3. a pull-up is required if the output is decoded, otherwise leave unconnected. (value of pull-up resistor depends on individual application. 4. a pull-up is required on a23 if it is decoded. pull-ups on whole bus minimize sleep mode power consumption. table 2-3. chip select signal summary signal name mnemonic input/ output three-state during bus arbitration pullup resistor required chip select cs3 ?s0 output no peripheral chip select cs2d /pa0, cs2c / pa1, cs2b /pa2 output (1) no note: 1. these signals have dual functions as port a i/o lines. their function is programmed in the port a control register.
signal description 2-4 mc68307 user? manual motorola table 2-4. interrupt port signal summary signal name mnemonic input/ output three-state during bus arbitration pullup resistor required interrupt request level 7 irq7 input (1) latched interrupt 1 int1 /pb8 input (2) (1) latched interrupt 2 int2 /pb9 input (2) (1) latched interrupt 3 int3 /pb10 input (2) (1) latched interrupt 4 int4 /pb11 input (2) (1) latched interrupt 5 int5 /pb12 input (2) (1) latched interrupt 6 int6 /pb13 input (2) (1) latched interrupt 7 int7 /pb14 input (2) (1) latched interrupt 8 int8 /pb15 input (2) (1) notes: 1. pullup or pulldown may be required (value depends on individual application). 2. these signals have dual functions as port b i/o lines. their function is programmed in the port b control register. table 2-5. clock and mode control signal summary signal name mnemonic input/ output three-state during bus arbitration pullup resistor required crystal oscillator or external clock extal input crystal oscillator xtal output system clock clkout output no initial bus width for cs0 busw0 input power-on reset rstin input (1) note: 1. pullup may be required (value depends on individual application). this pin must not be left ?ating. table 2-6. serial module signal summary signal name mnemonic input/ output three-state during bus arbitration pullup resistor required uart transmitter serial data txd/pb2 output (1) no uart receiver serial data rxd/pb3 input (1) uart request-to-send rtsa /pb4 output (1) no uart clear-to-send ctsa /pb5 input (1) (2) notes: 1. these signals have dual functions as port b i/o lines. their function is programmed in the port b control register. 2. pullup may be required (value depends on individual application). if used as ctsa this pin must not be left ?ating. table 2-7. jtag signal summary signal name mnemonic input/ output three-state during bus arbitration pullup resistor required test clock tck input test data input tdi input test data output tdo output test mode select tms input
signal description motorola mc68307 user? manual 2-5 2.1 bus signals the following signals are used for the mc68307 bus. 2.1.1 address bus (a23?0) the address bus signals are outputs that define the address of a byte (or the most significant byte) to be transferred during a bus cycle. the mc68307 places the address on the bus at the beginning of a bus cycle, it is valid while the address strobe output (as ) is asserted. the complete address bus (a23?0) is capable of addressing 16 mbytes of data. the address bus signals are three-stated when the mc68307 is arbitrated off the bus by an external bus master. they are also three-stated during reset of the ec000 core. the address bus consists of the following groups of signals. refer to section 3 bus oper- ation for information on the address bus and its relationship to bus operation. 2.1.1.1 address bus (a23?8). these signals are always used as address output lines. they are valid when address strobe (as ) is asserted. chip-selected memory and peripher- als, including 8051-compatible bus devices, need not decode the upper address bits, depending on the programmed block size for that chip select. 2.1.1.2 address bus (ad7?d0). in addition to carrying eight address signals a7?0, these low-order address lines also carry the 8-bit data bus during 8051-compatible bus cycles, as indicated by the relevant strobe signals (rd and wr ). at the start of each type of bus cycle (both m68000 and 8051-compatible), they carry the eight low-order address bits a7?0. in m68000 bus cycles, they are valid addresses when address strobe (as ) is asserted. chip select 3 (cs3 ) should be used to distinguish 8051 bus cycles if necessary. table 2-8. timer module signal summary signal name mnemonic input/ output three-state during bus arbitration pullup resistor required timer input 1 tin1/pb6 input (1) (2) timer input 2 tin2/pb7 input (1) (2) timer output 1 tout1/pa3 output (1) timer output 2 tout2/pa4 output (1) notes: 1. these signals have dual functions as port a and port b i/o lines. their function is programmed in the port a or port b control register. 2. pullup may be required (value depends on individual application). if used as timer inputs, these pins must not be left ?ating. table 2-9. m-bus module signal summary signal name mnemonic input/ output three-state during bus arbitration pullup resistor required m-bus clock scl/pb0 i/o (1) 2.2 k w m-bus data sda/pb1 i/o (1) 2.2 k w note: 1. these signals have dual functions as port b i/o lines. their function is programmed in the port b control register.
signal description 2-6 mc68307 user? manual motorola address line a0 is included for 8-bit data-bus interfaces only, i.e., the 8051-compatible bus, as described above, and also the dynamically-sized 68000 bus when programmed to use an 8-bit data-bus width. during 16-bit data-bus width cycles, the a0 output is meaningless, and should be ignored, as it may well hold a misleading value. the uds and lds signals should be used to further decode the even/odd byte access in this case. 2.1.2 data bus (d15?0) this 16-bit bidirectional parallel bus contains the data being transferred to or from the mc68307 during m68000 bus cycles. its value should be ignored during 8051-compatible bus read and write cycles, it is not three-stated in either case. a read or write operation may transfer 8 or 16 bits of data (one or two bytes) in one bus cycle. during an internal peripheral access, the data bus reflects the value read or written, for emu- lation and debug purposes. care is required, therefore, if external buffers are needed. the data bus has a programmable 8-bit bus size option for m68000 bus cycles, which is used in conjunction with the programmable chip-select dynamic bus sizing. if a chip select is configured for 8-bit port size, any 16-bit transfers appears externally as two 8-bit transfers. in this case, the 8-bit data uses the d15?8 lines only. 2.2 chip selects the programmable chip select outputs allow system designers to interface the mc68307 directly to memory and peripheral devices without having to perform address decode requir- ing additional external logic. although they can be programmed for many different configu- rations, each one has a particular usage to which it is tailored, giving added functionality. they are asserted coincident with the address strobe (as ) output, and are all active-low. refer to section 5 system integration module for details of how the chip selects can be programmed. 2.2.1 chip select 0 (cs0 ) this signal is the chip select for a boot rom containing the reset vectors and initialization program. from a cold reset, this chip select is asserted on every bus cycle in the first 8k bytes of address space until is is programmed otherwise. the busw0 pin specifies how this chip select behaves from cold reset, whether it is an 8-bit wide data bus access (busw0=0) or a 16-bit wide data bus access (busw0=1). 2.2.2 chip select 1 (cs1 ) this signal is primarily intended to be an enable for a ram memory device. from a cold reset, this signal does not assert until it is programmed with a valid base address and address mask. the data bus width for memory devices selected by this chip select is also programmable, between 8- and 16-bit data, in the system control register. 2.2.3 chip select 2 (cs2 , cs2b , cs2c , cs2d ) although the cs2 /cs2a pin can be used as a general-purpose m68000 chip-select (cs2 ), it can, together with the cs2b , cs2c, cs2d signals, be used to enable one of four miscel- laneous peripherals. the cs2 output address range can be relocated like any of the other
signal description motorola mc68307 user? manual 2-7 chip selects by programming, but it has the three extra enable outputs which are used to further divide this address space. if they are used, each of the four peripheral enable outputs decode fixed 16-kbyte address ranges within the confines of the programmed range of cs2 (which should therefore be a block 64k bytes in size). refer to section 5.1.2.2 peripheral chip selects and section 5.2.2 chip select registers for details. the data bus width for memory devices selected by this chip select is programmable, between 8- and 16-bit data, in the system control register. the cs2 /cs2a chip select signal has its own pin on the mc68307, but the three extra enable outputs cs2b , cs2c , cs2d are multiplexed with the port a input/output functions, and require to be programmed to use these pins at cold reset. this is done by setting bits in the port a control register (pacnt) as well as a bit in the system control register to enable the peripheral address decoder. as port a defaults to an input port on cold reset, these three additional peripheral chip select lines, if they are used, should have pullup resistors to ensure peripherals are not accidentally enabled during system initialization. when programmed as general-purpose input/output port lines, cs2b ? s2d function as pa0?a2. 2.2.4 chip select 3 (cs3 ) this chip select output can be programmed to perform an 8051-compatible bus cycle rather than a m68000 bus cycle. if 8051-compatible bus access is not required in a design, then this signal can be programmed to be a general purpose chip-select output. the data bus width for m68000-bus memory devices selected by this chip select is programmable, between 8- and 16-bit data, in the system control register. if the 8051-compatible bus inter- face is enabled, then the data-bus width for this chip select should be programmed to be 8 bits. the 8051-compatible bus has an address space (typically 64 kbytes long, but not restricted) which can be located anywhere in memory, as long as it does not overlap with other programmed chip select ranges. 2.3 bus control signals these are signals that may be decoded or provided by external logic, to control the various types of bus access which can occur. the bus control signals are three-stated whenever the mc68307 is arbitrated off the bus by an external bus master. 2.3.1 data transfer acknowledge (dtack ) this bidirectional, open-drain, active-low signal indicates that the data transfer has been completed. dtack is an output when it is generated internally by the programmable wait- state generators in the chip-select logic (including cs3 for 8051-compatible bus accesses), or during an access to internal peripheral registers. it is an input for all other m68000 bus cycles, i.e., when the mc68307 accesses an external device not within the range of the chip- select logic or when programmed to be generated externally for any particular chip-select. in this case, external logic must assert it in order to complete the bus cycle.
signal description 2-8 mc68307 user? manual motorola 2.3.2 address strobe (as ) this three-state active-low output signal indicates that there is a valid address on the address bus during m68000 bus cycles. it should be ignored during 8051-compatible bus cycles as the eight low-order address lines also carry the data bus during such a cycle. dur- ing all types of bus cycle, it should be taken into account when other bus masters are arbi- trating for the bus, as it indicates that the mc68307 is still using the bus. when the bus is arbitrated to an external master, or during reset, as is three-stated. 2.3.3 read/write (r/w ) this three-state output signal defines the data-bus transfer as a read or a write cycle. the r/w signal relates to the data strobe signals described in the following paragraphs. when the r/w line is high, the processor reads from the data bus. when the r/w line is low, the processor drives the data bus. the processor also drives the data bus during a read from an internal location, to aid emulation and debug. when the bus is arbitrated to an external master, or during reset, r/w is three-stated. 2.3.4 data strobes, upper and lower (uds , lds ) these three-state active-low output signals control the flow of data on the m68000 data bus. table 2-10 lists the combinations of these signals and the corresponding data on the bus in 16-bit wide mode. in 8-bit wide bus mode (programmed in conjunction with chip selects), all bus cycles appear as 8-bit reads or writes to the upper half of the data bus (d15?8), and so uds only is asserted. a0 should be used to determine even or odd byte being addressed in this case; it is valid whenever the external as signal is asserted during such a cycle. there is no external indication of data-bus width other than the chip-select asserted. the user has the knowledge of what bus width that chip-select is programmed to provide, for any given configuration of the mc68307 in a system. table 2-10. data strobe control of data bus uds lds r/w d15?8 d7?0 high high no valid data no valid data low low high valid data bits 15? valid data bits 7? high low high no valid data valid data bits 7? low high high valid data bus 15? no valid data low low low valid data bits 15? valid data bits 7? high low low valid data bits 7? valid data bits 7? low high low valid data bits 15? valid data bits 15?
signal description motorola mc68307 user? manual 2-9 when the bus is arbitrated to an external master, or during reset, uds and lds are three- stated. d7?0 should be regarded as invalid in 8-bit-wide bus mode. 2.3.5 8051 address latch enable (ale) this output signal is used to latch the low byte of address (ad7?d0 signals) during access to external 8051-compatible peripheral circuits. its function is tied to cs3 logic which can be programmed to locate the 8051-compatible bus address space anywhere in the memory map. for a discussion of the timing of the 8051-compatible bus signals, refer to section 3 bus operation . ale is not three-stated during external bus mastership or system reset. 2.3.6 8051-compatible bus read (rd ) this active-low output indicates that the bus cycle in progress is an 8051 read cycle, and that an addressed 8051 peripheral should provide data on the ad7?d0 lines within the specified access time. rd is not three-stated during external bus mastership or system reset. 2.3.7 8051-compatible bus write (wr ) this active-low output indicates that the bus cycle in progress is an 8051 write cycle, and that an addressed 8051 peripheral should accept the valid data which is now on the ad7-ad0 lines. wr is not three-stated during external bus mastership or system reset. 2.3.8 bus width select for cs0 (busw0) the state on this input pin is read at reset, and is used to choose the data bus width for mem- ory accesses for cs0 (refer to section 5.2.1.2 system control register (scr) ). hold busw0 low for an 8-bit data bus, or high for a 16-bit data bus during bus cycles which trigger cs0 . busw0 does not choose the bus width for cs1 , cs2 or cs3 ; that is done by user ini- tialization code. internally, the mc68307 always has a 16-bit bus. 2.4 exception control signals the following paragraphs describe the exception control signals. 2.4.1 reset (reset ) the external assertion of this bidirectional active-low signal simultaneously with the asser- tion of halt starts a system initialization sequence by resetting the whole mc68307 (pro- cessor, sim, and internal peripherals). this is called a cold reset or system reset. the processor assertion of reset (from executing a reset instruction) resets all external devices of a system and internal peripherals of the mc68307 without affecting the initial state of the processor, chip select logic, port configuration, or interrupt configuration. this is called a software reset or peripheral reset. refer to section 3 bus operation for further information on reset operation. during a cold reset, the address bus, data bus, and bus control pins (as , uds , lds , r/w ) are all three-stated. chip select outputs, cs3 ? s0 , remain high. none of these signals are three-stated during a peripheral reset.
signal description 2-10 mc68307 user? manual motorola 2.4.2 power-on reset (rstin ) this active-low input signal causes the mc68307 (processor, sim, and peripherals) to enter the reset state (cold reset). the assertion of rstin causes reset to be asserted out to reset external circuitry; however, note that halt is not asserted as a result of rstin asser- tion. internal power-on reset circuitry provides a reset pulse of at least 32768 clocks width at power-on or when rstin is subsequently asserted. this reset pulse length can be extended by adding an external rc network, to ensure that rstin is held low for long enough to apply the reset pulse for 128 cpu clocks after v cc and clock are stable. refer to section 10.1 mc68307 minimum stand-alone system hardware for an example circuit. 2.4.3 halt (halt ) this active-low bidirectional signal can be asserted with reset to cause a cold reset as above. if asserted alone, it causes the processor to stop after completion of the current bus cycle. as long as halt is held asserted, all bus control signals go to their inactive state, except bgack , and all three-state bus signals (a23?0, d15?0 only) are placed in the high-impedance state. when the processor has stopped executing instructions (e.g., after a double bus fault), the mc68307 asserts this signal. 2.4.4 bus request (br /pa5) this input signal indicates to the mc68307 that an external device desires to become the bus master on the mc68307 external bus. refer to section 3 bus operation for details of the bus arbitration features. when programmed as general-purpose input/output, this signal functions as bit 5 of port a. 2.4.5 bus grant (bg /pa6) this output signal indicates to all external bus master devices (if any) that the mc68307 releases bus control at the end of the current bus cycle to an external requesting bus master. during cold reset, bg reflects the value of br . when programmed as general-purpose input/ output, this signal functions as bit 6 of port a. 2.4.6 bus grant acknowledge (bgack /pa7) this input signal indicates that some other device besides the mc68307 has become the bus master. when programmed as general-purpose input/output, this signal functions as bit 7 of port a. 2.5 clock signals the following paragraphs describe the clock signals. 2.5.1 crystal oscillator (extal, xtal) this input provides two clock generation options (crystal and external clock). extal may be used with xtal to connect an external crystal to the on-chip oscillator and clock gener- ator. if an external clock is used, the clock source should be connected to extal, and xtal must be left unconnected. the oscillator uses an internal frequency equal to the external crystal frequency. the frequency of extal may range from dc to 16.67 mhz, although if a
signal description motorola mc68307 user? manual 2-11 crystal is used it should be in the range 1 mhz to 16.67 mhz. when an external clock is used, it must provide a cmos level at the required system clock frequency. 2.5.2 clock output (clkout) this output clock signal is derived from the on-chip clock oscillator. this clock is used by the processor and the internal peripherals. all mc68307 bus timings are referenced to the clk- out signal rather than the extal input signal, as there is a skew between the two. the clock output is active from reset, but can be turned off by the software writing to the system control register, in order to save power or control external devices. 2.6 test signals the following signals are used with the on-board test logic defined by the ieee 1149.1 stan- dard. refer to section 9 ieee 1149.1 test access port for more information on the use of these signals. 2.6.1 test clock (tck) this input provides a clock for on-board test logic defined by the ieee1149.1 standard. 2.6.2 test mode select (tms) this input controls test mode operations for on-board test logic defined by the ieee 1149.1 standard. connecting tms to v cc disables the test controller, making all jtag circuits transparent to the system. 2.6.3 test data in (tdi) this input is used for serial test instructions and test data for on-board test logic defined by the ieee 1149.1 standard. 2.6.4 test data out (tdo) this output is used for serial test instructions and test data for on-chip test logic defined by the ieee 1149.1 standard. 2.7 m-bus i/o signals the m-bus is an i 2 c-bus-compatible serial interface on two wires. all devices connected to the bus must have open-drain or open-collector outputs. the logical and function is exer- cised on both lines with pullup resistors being required. the pins are multiplexed with port b, individual pin function being programmable. port b bits 0 and 1 are therefore always open-drain input/outputs. refer to section 7 m-bus interface module for more information on these signals. 2.7.1 serial clock (scl/pb0) this bidirectional open-drain signal is the clock signal for the m-bus interface. either it is driven by the m-bus module when the bus is in the master mode or it becomes the clock input when the m-bus is in the slave mode. when programmed as general-purpose input/ output, this signal functions as bit 0 of port b.
signal description 2-12 mc68307 user? manual motorola 2.7.2 serial data (sda/pb1) this bidirectional open-drain signal is the data input/output for the m-bus interface. when programmed as general-purpose input/output, this signal functions as bit 1 of port b. 2.8 uart i/o signals the following signals are used by the uart serial i/o module for data and clock signals. refer to section 8 serial module for more information on these signals. 2.8.1 transmit data (txd/pb2) this bidirectional signal can be programmed as the transmitter serial data output for the uart module. the output is held high ('mark' condition) when the transmitter is disabled, idle, or operating in the local loopback mode. data is shifted out on this signal at the falling edge of the serial clock source, with the least significant bit transmitted first. when pro- grammed as a general-purpose input/output, this signal functions as bit 2 of the 16-bit sec- ondary port, port b. 2.8.2 receive data (rxd/pb3) this bidirectional signal can be programmed as the receiver serial data input for the uart module. data received on this signal is sampled on the rising edge of the serial clock source, with the least significant bit received first. when the uart clock has been stopped for power-down mode, any transition on this pin can optionally restart it. when programmed as a general-purpose input/output, this signal functions as bit 3 of port b. 2.8.3 request-to-send (rts /pb4) this bidirectional signal can be programmed as an active-low request-to-send output from the uart module. when programmed as a general-purpose input/output, this signal func- tions as bit 4 of port b. 2.8.4 clear-to-send (cts /pb5) this bidirectional input signal can be programmed as the active-low clear-to-send input for the uart module. when programmed as general-purpose input/output, this signal func- tions as bit 5 of port b. 2.9 timer i/o signals the following external signals are used by the timer module. refer to section 6 dual timer module for additional information on these signals. 2.9.1 timer 1 input (tin1/pb6) this bidirectional signal can be programmed as a clock input that causes events to occur in timer/counter channel 1, either causing a clock to the event counter or providing a trigger to the timer value capture logic. when programmed as a general-purpose input/output, this signal functions as bit 6 of port b.
signal description motorola mc68307 user? manual 2-13 2.9.2 timer 2 input (tin2/pb7) this bidirectional signal can be programmed as a clock input that causes events to occur in timer/counter channel 2, either causing a clock to the event counter or providing a trigger to the timer value capture logic. when programmed as general-purpose input/output, this sig- nal functions as bit 7 of port b. 2.9.3 timer 1 output (tout1 /pa3) this bidirectional signal can be programmed to toggle or pulse low for one system clock duration when timer/counter channel 1 reaches a reference value. when programmed as general-purpose i/o, this signal functions as bit 3 of port a. 2.9.4 timer 2 output (tout2 /pa4) this bidirectional signal can be programmed to toggle or pulse low for one system clock duration when timer/counter channel 2 reaches a reference value. when programmed as general-purpose i/o, this signal functions as bit 4 of port a. 2.10 interrupt request inputs these pins can be programmed to be either prioritized interrupt request lines or port b gen- eral-purpose input/output lines. 2.10.1 interrupt inputs (int1 ?nt8 /pb8?b15) these eight bidirectional signals may be configured as general-purpose parallel i/o ports with interrupt capability. each of the pins can be configured either as an input or an output. when configured as an input, each pin can generate a separate, maskable interrupt on a high-to-low transition, which is latched internally. the interrupt request level (ipl) can be programmed individually for each pin, and each causes a unique vector to be fetched during the subsequent interrupt processing. 2.10.2 non-maskable interrupt input (irq7 ) irq7 is the highest priority interrupt available to the ec000 core, it is a nonmaskable inter- rupt (ipl=7) and cannot be superseded by any other interrupt request. this is an active-low input. 2.11 use of pullup resistors in general, pins that are input-only or output-only do not require external pullup resistors. however, see the notes on low power consumption in the following paragraphs. the open-drain bidirectional signals (halt , reset , dtack , scl/pb0, sda/pb1) always require pullup resistors. the bus control outputs (as , uds , lds , r/w ) three-state at reset during bus arbitration and low-power sleep mode. they need pullups only if they are decoded for use in the user? design or if minimum power consumption is required, otherwise they can be left as unconnected outputs.
signal description 2-14 mc68307 user? manual motorola the address and data bus also three-state at reset and during bus arbitration and power- down mode. in this case the designer must decide whether a short period of floating values on the bus is a concern. the internal pullups on the bidirectional data bus pins are not sufficient to drive external levels. again, adding pullups will help minimize power consumption in low-power sleep mode. bidirectional i/o pins default to inputs on reset. if they are to be used as outputs later, or their function changed to an alternate output function for the pin then a pullup or pulldown may be required. one example is the cs2b , cs2c , and cs2d signals, multiplexed with port a lines. if these chip-selects are used they should have pullups otherwise they will float from reset until they are setup. the rstin input can either be left floating or pulled up if the default power-on reset time is required, or can have an external rc network to stretch reset time. refer to section 3.5 reset operation and section 10.1 mc68307 minimum stand-alone system hardware for details of use of this pin. for maximum reliability, unused inputs should not be left floating. if they are input-only, they may be pulled to v cc or ground. unused outputs may be left unconnected. unused i/o pins may be configured as outputs after reset, and left unconnected. if the mc68307 is to be held in reset for extended periods of time in an application (other than what occurs in normal power-on reset or board test sequences) due to a special appli- cation requirement (such as v cc dropping below required specifications, etc.) then three- stated signals and inputs should be pulled up or down. this decreases stress on the device transistors and saves power. refer to section 2.4.1 reset (reset) and section 3.5 reset operation for the condition of all pins during reset. refer to section 12 ordering information and mechanical data for details of pin assign- ments. 2.12 signal index table 2-11 lists the signal index. table 2-11. signal index pin name description of pin function(s) direction tdo test data out output tdi test data in input tms test mode select input tck test clock in input d15?0 data bus bidirectional a23?8 address bus out output a7?0/ad7?d0 address bus out/multiplexed 8051 address/data bidirectional as address strobe output uds upper data strobe output lds lower data strobe output r/w read/write output
signal description motorola mc68307 user? manual 2-15 dtack data acknowledge bidirectional halt system halt bidirectional reset system reset bidirectional rstin power-on reset input cs0 chip select 0 (rom) output cs1 chip select 1 (ram) output cs2 /cs2a chip select 2 (peripherals) output cs3 chip select 3 (8051) output ale 8051-address latch enable output rd 8051-bus read output wr 8051-bus write output extal external clock/crystal in input xtal external crystal output clkout clock to system output busw0 initial data bus width for cs0 input cs2b /pa0 chip select 2b/i/o port a bit 0 bidirectional cs2c /pa1 chip select 2c/i/o port a bit 1 bidirectional cs2d /pa2 chip select 2d/i/o port a bit 2 bidirectional tout1 /pa3 timer 1 output/i/o port a bit 3 bidirectional tout2 /pa4 timer 2 output/i/o port a bit 4 bidirectional br /pa5 bus request input/i/o port a bit 5 bidirectional bg /pa6 bus grant output/i/o port a bit 6 bidirectional bgack /pa7 bus grant acknowledge output/i/o port a bit 7 bidirectional irq7 interrupt level 7 input scl/pb0 serial m-bus clock/port b bit 0 bidirectional sda/pb1 serial m-bus data/port b bit 1 bidirectional txd/pb2 uart transmit data/port b bit 2 bidirectional rxd/pb3 uart receive data/port b bit 3 bidirectional rts /pb4 request-to-send/port b bit 4 bidirectional cts /pb5 clear-to-send/port b bit 5 bidirectional tin1/pb6 timer 1 input/port b bit 6 bidirectional tin2/pb7 timer 2 input/port b bit 7 bidirectional int1 /pb8 interrupt in 1/port b bit 8 bidirectional int2 /pb9 interrupt in 2/port b bit 9 bidirectional int3 /pb10 interrupt in 3/port b bit 10 bidirectional int4 /pb11 interrupt in 4/port b bit 11 bidirectional int5 /pb12 interrupt in 5/port b bit 12 bidirectional int6 /pb13 interrupt in 6/port b bit 13 bidirectional int7 /pb14 interrupt in 7/port b bit 14 bidirectional int8 /pb15 interrupt in 8/port b bit 15 bidirectional table 2-11. signal index (continued) pin name description of pin function(s) direction
motorola mc68307 user? manual 3-1 section 3 bus operation this section describes control signal and bus operation during data transfer operations, bus arbitration, bus error and halt conditions, and reset operation. note the terms assertion and negation are used extensively in this manual to avoid confusion when describing a mixture of ?ctive- low?and ?ctive-high?signals. the term assert or assertion is used to indicate that a signal is active or true, independently of whether that level is represented by a high or low voltage. the term negate or negation is used to indicate that a signal is inac- tive or false. 3.1 data transfer operations transfer of data between devices involves the following signals: 1. a23?0 2. d7?0 and/or d15?0 3. control signals the address and data buses are separate parallel buses used to transfer data using an asynchronous bus structure. in all cases, the bus master must deskew all signals it issues at both the start and end of a bus cycle. in addition, the bus master must deskew the acknowledge and data signals from the slave device. the 8051-compatible bus uses a23?0 for both address and data. 3.1.1 16-bit m68000 bus operation the m68000 16-bit bus mode of operation is the default mode of the mc68307. the internal data bus width is 16-bits, and the ec000 core always operates in a 16-bit mode. this mode is appropriate for: external 16-bit memory and peripheral devices, which read and write from the whole data bus, or 8-bit peripherals which do not require a contiguous address space, that is, they occupy either even byte locations only (if connected to the upper half of the data bus) or odd byte locations only (if connecetd to the lower half of the data bus). thi d t t d ith f m k 4 0 4
bus operation 3-2 mc68307 user? manual motorola in this mode address bus a23?1 is used, with data bus d15?0 and control signals as , uds , lds , r/w , and dtack . 3.1.2 16-bit m68000 bus read cycle during a read cycle, the processor receives either one or two bytes of data from the memory or from a peripheral device. if the instruction specifies a word or long-word operation, the processor reads both upper and lower bytes simultaneously by asserting both upper and lower data strobes. a long-word read is accomplished by two consecutive word reads. when the instruction specifies byte operation, the processor uses the internal a0 bit to determine which byte to read and issues the appropriate data strobe. when a0 is zero, the upper data strobe is issued; when a0 is one, the lower data strobe is issued. when the data is received, the processor internally positions the byte appropriately. the word read cycle flowchart is shown in figure 3-1. the byte read cycle flowchart is shown in figure 3-2. the read and write cycle timing is shown in figure 3-3. figure 3-4 shows the word and byte read cycle timing diagram. figure 3-1. word read cycle flowchart (16-bit bus) bus master slave acquire the data input the data start next cycle 1) set r/w to read 2) place address on a23?1 3) assert address strobe (as ) 4) assert upper data strobe (uds ) and lower data strobe (lds ) terminate the cycle address the device 1) latch data 2) negate u ds and l ds 3) negate as 1) decode address 2) place data on d15?0 3) assert data transfer acknowledge (dtack ) 1) remove data from d15?0 2) negate dtack
bus operation motorola mc68307 user? manual 3-3 figure 3-2. byte read cycle flowchart (16-bit bus) figure 3-3. read and write cycle timing diagram (16-bit bus) bus master slave acquire the data input the data start next cycle 1) set r/w to read 2) place address on a23?1 3) assert address strobe (as ) 4) assert upper data strobe (uds ) or lower data strobe (lds ) (based on a0) terminate the cycle address the device 1) latch data 2) negate u ds and l ds 3) negate as 1) decode address 2) place data on d7?0 or d15?8 (based on uds or lds ) 3) assert data transfer acknowledge (dtack ) 1) remove data from d7?0 or d15?8 2) negate dtack s0 s1 s2 s3 s4 s5 s6 s7 s0 s1 s2 s3 s4 s5 s6 s7 s0 s1 s2 s3 s4 w w w w s5 s6 s7 clk a23?0 as uds lds r/w dtack d15?8 d7?0 read write 2 wait state read
bus operation 3-4 mc68307 user? manual motorola a bus cycle consists of eight states. the various signals are asserted during specific states of a read cycle as follows: state 0 the read cycle starts in state 0 (s0). the processor places a valid address on the bus, and drives r/w high to identify a read cycle. state 1 during state 1 (s1), no bus signals are altered. state 2 on the rising edge of state 2 (s2), the processor asserts as and uds /lds . state 3 during state 3 (s3), no bus signals are altered. state 4 during state 4 (s4), the processor waits for a cycle termination signal (dtack or berr ). if neither termination signal is asserted before the falling edge at the end of s4, the processor inserts wait states (full clock cycles) until either dtack or berr is asserted. note that the berr signal does not appear on an external pin on the mc68307; the internal hardware watchdog generates it. case 1: dtack received, with or without berr . state 5 during state 5 (s5), no bus signals are altered. state 6 sometime between state 2 (s2) and state 6 (s6), data from the device is driven onto the data bus. figure 3-4. word and byte read cycle timing diagram (16-bit bus) s0 s1 s2 s3 s4 s5 s6 s7 s0 s1 s2 s3 s4 s5 s6 s7 s0 s1 s2 s3 s4 s5 s6 s7 clk a23?1 as uds lds r/w dtack d15?8 d7?0 word odd byte read even byte read a0
bus operation motorola mc68307 user? manual 3-5 state 7 on the falling edge of the clock entering state 7 (s7), the processor latches data from the addressed device and negates as and uds , lds . the device negates dtack at this time. case 2: berr received without dtack . state 5 during state 5 (s5), no bus signals are altered. state 6 during state 6 (s6), no bus signals are altered. state 7 during state 7 (s7), no bus signals are altered. state 8 during state 8 (s8), no bus signals are altered. state 9 as and uds /lds negated. slave negates berr . 3.1.3 16-bit m68000 bus write cycle during a write cycle, the processor sends bytes of data to the memory or peripheral device. if the instruction specifies a word or long-word operation, the processor issues both uds and lds and writes both bytes. a long-word write is accomplished by two consecutive word writes. when the instruction specifies a byte operation, the processor uses the internal a0 bit to determine which byte to write and issues the appropriate data strobe. when the a0 bit equals zero, uds is asserted; when the a0 bit equals one, lds is asserted. the word write cycle flowchart is shown in figure 3-5. the byte write cycle flowchart is shown in figure 3- 1. the word and byte write cycle timing is shown in figure 3-7. figure 3-5. word write cycle flowchart (16-bit bus) bus master slave terminate output transfer input the data start next cycle 1) place address on a23?1 2) assert address strobe (as ) 3) set r/w to write 4) placr data on d15?0 5) assert upper data strobe (uds ) and lower data strobe (lds ) terminate the cycle address the device 1) negate u ds and l ds 3) negate as 3) remove data from d15?0 4) set r/w to read 1) decode address 2) latch data on d15?0 3) assert data transfer acknowledge (dtack ) 1) negate dtack
bus operation 3-6 mc68307 user? manual motorola figure 3-6. byte write cycle flowchart (16-bit bus) figure 3-7. word and byte write cycle timing diagram bus master slave terminate output transfer input the data start next cycle 1) place address on a23?1 2) assert address strobe (as ) 3) set r/w to write 4) place data on d7?0 or d15?8 (according to internal a0) 5) assert upper data strobe (uds ) or lower data strobe (lds ) (based on internal a0) terminate the cycle address the device 1) negate u ds and l ds 2) negate as 3) remove data from d7?0 or d15?8 4) set r/w to read 1) decode address 2) latch data on d7?0 if lds is asserted. latch data on d15?8 if uds is asserted 3) assert data transfer acknowledge (dtack ) 1) negate dtack s0 s1 s2 s3 s4 s5 s6 s7 s0 s1 s2 s3 s4 s5 s6 s7 s0 s1 s2 s3 s4 s5 s6 s7 a0 clk a23?1 as uds lds r/w dtack d15?8 d7?0 even byte write word write odd byte write
bus operation motorola mc68307 user? manual 3-7 the descriptions of the eight states of a write cycle are as follows: state 0 the write cycle starts in s0. the processor places a valid address on the address bus, and drives r/w high (if a preceding write cycle has left r/w low). state 1 during s1, no bus signals are altered. state 2 on the rising edge of s2, the processor asserts as and drives r/w low. state 3 during s3, the data bus is driven out of the high-impedance state as the data to be written is placed on the bus. state 4 at the rising edge of s4, the processor asserts uds and/or lds ;. the processor waits for a cycle termination signal (dtack or berr ). if neither termination signal is asserted before the falling edge at the end of s4, the processor inserts wait states (full clock cycles) until either dtack or berr is asserted. note that the berr signal does not appear on an external pin on the mc68307; the internal hardware watchdog generates it. case 1: dtack received, with or without berr . state 5 during s5, no bus signals are altered. state 6 during s6, no bus signals are altered. state 7 on the falling edge of the clock entering s7, the processor negates as , uds , and/or lds . as the clock rises at the end of s7, the processor places the data bus in the high-impedance state, and drives r/w high. the device negates dtack or berr at this time. case 2: berr received without dtack . state 5 during state 5 (s5), no bus signals are altered. state 6 during state 6 (s6), no bus signals are altered. state 7 during state 7 (s7), no bus signals are altered. state 8 during state 8 (s8), no bus signals are altered. state 9 as and uds /lds negated. slave negates berr . at the end of s9, three- state data and drive r/w high.
bus operation 3-8 mc68307 user? manual motorola 3.1.4 read-modify-write cycle the read-modify-write cycle performs a read operation, modifies the data in the arithmetic logic unit, and writes the data back to the same address. the address strobe (as ) remains asserted throughout the entire cycle, making the cycle indivisible. the test and set (tas) instruction uses this cycle to provide a signaling capability without deadlock between pro- cessors in a multiprocessing environment. the tas instruction (the only instruction that uses the read-modify-write cycle) only operates on bytes. thus, all read-modify-write cycles are byte operations. the read-modify-write flowchart is shown in figure 3-8 and the timing diagram is shown in figure 3-9. the descriptions of the read-modify-write cycle states are as follows: state 0 the read cycle starts in s0. the processor places a valid address on the address bus, and drives r/w high to identify a read cycle. figure 3-8. read-modify-write cycle flowchart bus master slave start output transfer input the data start next cycle 1) set r/w to read 2) place address on a23?1 3) assert address strobe (as ) 4) assert upper data strobe (uds ) or lower data strobe (lds ) terminate the cycle address the device 1) set r/w to write 2) place data on d7?0 or d15?8 3) assert upper data strobe (uds ) or lower data strobe (lds ) 1) decode address 2) place data on d7?0 or d15?8 3) assert data transfer acknowledge (dtack ) 1) remove data from d7?0 or d15?8 2) negate dtack acquire the data 1) latch data 2) negate uds and lds 3) start data modification input the data 1) store data on d7?0 or d15?8 2) assert data transfer acknowledge (dtack ) terminate the cycle 1) negate dtack terminate output transfer 1) negate u ds and l ds 2) negate as 3) remove data from d7?0 or d15?8 4) set r/w to read
bus operation motorola mc68307 user? manual 3-9 state 1 during s1, no bus signals are altered. state 2 on the rising edge of s2, the processor asserts as and uds /lds . state 3 during s3, no bus signals are altered. state 4 during s4, the processor waits for a cycle termination signal (dtack or berr ). if neither termination signal is asserted before the falling edge at the end of s4, the processor inserts wait states (full clock cycles) until either dtack or berr is asserted. case r1: dtack only. state 5 during s5, no bus signals are altered. state 6 during s6, data from the device are driven onto the data bus. state 7 on the falling edge of the clock entering s7, the processor accepts data from the device and negates uds /lds . the device negates dtack or berr at this time. state 8?1 the bus signals are unaltered during s8?11, during which the arithmetic logic unit makes appropriate modifications to the data. state 12 the write portion of the cycle starts in s12. the address bus lines, as and r/ w remain unaltered. state 13 during s13, no bus signals are altered. state 14 on the rising edge of s14, the processor drives r/w low. figure 3-9. read-modify-write cycle timing diagram clk a23?0 as s0 s1 s2 s3 s4 s5 s6 s7 s8 s9 s10 s11 s12 s13 s14 s15 s16 s17 s18 s19 indivisible cycle uds or lds r/w dtack d15?8 or d7?0 fc2?c0
bus operation 3-10 mc68307 user? manual motorola state 15 during s15, the data bus is driven out of the high-impedance state as the data to be written are placed on the bus. state 16 at the rising edge of s16, the processor asserts uds /lds . the processor waits for dtack or berr . if neither termination signal is asserted before the falling edge at the close of s16, the processor inserts wait states (full clock cycles) until either dtack or berr is asserted. case w1: dtack with or without berr . state 17 during s17, no bus signals are altered. state 18 during s18, no bus signals are altered. state 19 on the falling edge of the clock entering s19, the processor negates as and uds /lds . as the clock rises at the end of s19, the processor places the data bus in the high-impedance state, and drives r/w high. the device negates dtack or berr at this time. case r2: dtack and berr on read. state 5 during s5, no bus signals are altered. state 6 during s6, no bus signals are altered, and data from the device is ignored. state 7 as and uds /lds are negated. the cycle terminates without the write portion. case r3: berr only on read. state 5 during s5, no bus signals are altered. state 6 during s6, no bus signals are altered. state 7 during s7, no bus signals are altered. state 8 during s8, no bus signals are altered. state 9 as and uds /lds are negated. the cycle terminates without the write portion. case w2: berr only on write. state 17 during s17, no bus signals are altered. state 18 during s18, no bus signals are altered. state 19 during s19, no bus signals are altered. state 20 during s20, no bus signals are altered. state 21 the processor negates as and uds /lds .
bus operation motorola mc68307 user? manual 3-11 3.1.5 cpu space cycle a cpu space cycle, indicated when the internal function codes are all high, is a special pro- cessor cycle. in the ec000 core, cpu space is used only for interrupt acknowledge cycles. figure 3-10 shows the encoding of an interrupt acknowledge cycle. no response is expected or allowed from external devices. on the mc68307 this cycle is an indication of the internal interrupt controller? vector response. as the mc68307 implementation does not provide function code pins to differentiate cpu space cycles (the internal function code signals are all high in this type of cycle), care is required when decoding addresses which may match the above address. no problems will be encountered as long as the chip selects are used as a term in the decoding logic. this will ensure that cpu space cycles are not decoded. the interrupt acknowledge cycle places the level of the interrupt being acknowledged on address bits a3?1 and drives all other address lines high. the interrupt acknowledge cycle reads a vector number when the mc68307 interrupt controller places a vector number on the data bus. the timing diagram for an interrupt acknowledge cycle is shown in figure 3-11. 3.1.6 8-bit m68000 dynamically-sized bus m68000 8-bit bus cycles appear when the mc68307 dynamic bus sizing is enabled. this bus sizing adds cycle-by-cycle control of data bus width to the ec000 core bus, as for the mc68020, but with the difference that the bus width is controlled via the chip selects, rather than external dsack1 and dsack0 inputs. this provides the flexibility of differing bus widths for ram, rom and peripherals, without the pin overhead of the mc68020 solution (dsack1 , dsack0 , siz1 and siz0 ). each of the four programmable chip selects has a default bus width of 8- or 16-bits associ- ated with it. the initial bus width of cs0 is set upon reset by the state of the busw external pin (0 for an 8-bit data bus, 1 for a 16-bit data bus). the bus widths for cs2 , cs3 and cs4 should be programmed during system initialization using the buswx bits in the system configuration register (scr), according to the system design. the default after reset is 16-bits wide. all bus accesses not matched by any of the chip selects or the internal peripheral address ranges require an external dtack input to terminate the cycle. the data bus width of such cycles is 16-bits by default; the ebusw bit in the system configuration register (scr) can be cleared to specify external dtack cycles as 8-bit data bus. figure 3-10. interrupt acknowledge cycle ?address bus 11111111111111111111 interrupt acknowledge level 1 310 23
bus operation 3-12 mc68307 user? manual motorola when using the m68000 8-bit bus, transfer of the data between the mc68307 and other de- vices on the bus involves the following signals: address bus a23?0 data bus d15?0 control signals (as , uds , r/w , dtack ). lds is not used. all m68000 8-bit bus cycles use the upper half of the data bus (d15?8) for reads and writes. note that this differs from the static 8-bit bus provided by the mc68hc001, mc68008 and mc68302, which use the lower half (d7?0). therefore, only uds is asserted during such cycles, never lds . the chip select logic can control the data strobes in this way only because it determines the bus width that is pro- grammed for a particular chip-select before dtack is asserted. figure 3-11. interrupt acknowledge cycle timing diagram clk a23?4 as uds * lds r/w dtack d15?8 d7?0 ipl2?pl0 (internal) stack pcl (ssp) iack cycle (vector number acquisition) stack and vector fetch a3?0 although a vector number is one byte, both data strobes are asserted due to the microcode used for exception processing. the processor does not recognize anything on data lines d15?8 at this time. last bus cycle of instruction (read or write) s0 s1 s2 s3 s4 s5 s6 s7 s0 s1 s2 s3 s4 s5 s6 s7 s0 s1 s2 s3 s4 s5 s6 * ipl2?pl0 transition ipl2?pl0 sampled ipl2?pl0 valid internally
bus operation motorola mc68307 user? manual 3-13 3.1.7 8051-bus operation the 8051-compatible bus is a multiplexed address/data bus scheme which provides an 8- bit-wide data interface to memories and peripherals. it is typically used for asic devices where pin count minimization is important. individual read and write strobes are provided, along with a latch enable signal which indi- cates that the multiplexed portion of the bus is carrying a valid address which is latched by the memory or peripheral device at the beginning of the cycle. when using the 8051-compatible 8-bit bus, transfer of data between the mc68307 and other devices on the bus involves the following signals: address/data multiplexed bus ad7?d0 optionally higher-order address bus a23?8 or part thereof control signals (cs3 , ale, rd , wr ) if the 8051-compatible interface is enabled, one of the mc68307 programmable chip selects (cs3 ) is used to indicate the address range to be decoded as 8051 accesses. the base address and address mask should be programmed as described in section 5.1.2.3 8051- compatible bus chip select . the device being addressed can decode address lines a8 and higher if an addressing range larger than 256-bytes is required, up to the maximum address range of the mc68307. during 8051-compatible bus cycles, the m68000 strobe outputs are still asserted, indicating the ?nderlying?m68000 bus-cycle, and the d15?0 outputs reflect the internal data-bus value being presented to the ec000 processor core. figure 3-12 and figure 3-13 show examples of 8051-compatible read and write cycle timing diagrams, respecitively.
bus operation 3-14 mc68307 user? manual motorola figure 3-12. 8051-compatible read cycle signals figure 3-13. 8051-compatible write cycle signals ale rd ad7 ?ad0 d15?0 address data out address data xds as clk cs3 a23?8 address ale wr ad7 ?ad0 d15?0 address data out address data xds as clk cs3 a23?8 address
bus operation motorola mc68307 user? manual 3-15 3.2 bus arbitration bus arbitration is a technique used by bus master devices to request, to be granted, and to acknowledge bus mastership. bus arbitration consists of the following: 1. asserting a bus mastership request 2. receiving a grant indicating that the bus is available at the end of the current cycle 3. acknowledging that mastership has been assumed figure 3-14 is a flowchart showing the bus arbitration cycle of the ec000 core. figure 3-16 is a timing diagram of the bus arbitration cycle charted in figure 3-14. this technique allows processing of bus requests during data transfer cycles. there are two ways to arbitrate the bus; three-wire and two-wire bus arbitration. the ec000 core can do either two-wire or three-wire bus arbitration. figure 3-14 and figure 3-16 show figure 3-14. three-wire bus arbitration cycle flowchart processor requesting device request the bus rearbitrate or resume assert bus grant (bg ) acknowledge bus mastership grant bus arbitration assert bus request (br ) 1) external arbitration determines next bus master 2) next bus master waits for current cycle to complete 3) next bus master asserts bus grant acknowledge (bgack ) to become new master 4) bus master negates br terminate arbitration 1) negate bg (and wait for bgack to be negated) 2) if br remains asserted after bgack asserted, re-assert bg operate as bus master perform data transfers (read and write cycles) according to the same rules as the processor uses release bus mastership negate bgack processor operation
bus operation 3-16 mc68307 user? manual motorola three-wire bus arbitration and figure 3-15 and figure 3-17 show two-wire bus arbitration. bgack must be pulled high for two-wire bus arbitration. the timing diagram in figure 3-16 shows that the bus request is negated at the time that an acknowledge is asserted. this type of operation applies to a system consisting of a proces- sor and one other device capable of becoming bus master. in systems having several devices that can be bus masters, bus request lines from these devices can be wire-ored at the processor, and more than one bus request signal could occur. the bus grant signal is negated a few clock cycles after the assertion of the bus grant acknowledge signal. however, if bus requests are pending, the processor reasserts bus grant for another request a few clock cycles after bus grant (for the previous request) is negated. in response to this additional assertion of bus grant, external arbitration circuitry selects the next bus master before the current bus master has completed the bus activity. the timing diagram in figure 3-17 also applies to a system consisting of a processor and one other device capable of becoming bus master. since the two-wire bus arbitration scheme does not use a bus grant acknowledge signal, the external master must continue to assert br until it has completed its bus activity. the processor negates bg when br is negated. figure 3-15. two-wire bus arbitration cycle flowchart processor requesting device request the bus rearbitrate or resume assert bus grant (bg ) operate as bus master grant bus arbitration assert bus request (br ) 1) external arbitration determines next bus master 2) next bus master waits for current cycle to complete acknowledge release of negate bus grant (bg ) release bus mastership negate bus request (br ) processor operation bus mastership
bus operation motorola mc68307 user? manual 3-17 3.2.1 requesting the bus external devices capable of becoming bus masters assert br to request the bus. this signal can be wire-ored (not necessarily constructed from open-collector devices) from any of the devices in the system that can become bus master. the processor, which is at a lower bus priority level than the external devices, relinquishes the bus after it completes the current bus cycle. figure 3-16. three-wire bus arbitration timing diagram figure 3-17. two-wire bus arbitration timing diagram clk a23?0 as lds/ uds r/w dtack d15?0 br bg bgack processor dma device processor dma device clk a23?0 as ds r/w dtack d7?0 processor br bg s0 s6 s2 s4 s0 s2 s4 s6 s0 s2 s4 s6 s0 s2 s4 s6 dma device processor dma device
bus operation 3-18 mc68307 user? manual motorola 3.2.2 receiving the bus grant the processor asserts bg as soon as possible. normally, this process immediately follows internal synchronization, except when the processor has made an internal decision to exe- cute the next bus cycle but has not yet asserted as for that cycle. in this case, bg is delayed until as is asserted to indicate to external devices that a bus cycle is in progress. one such case is during a dynamically sized cycle; bg will not assert until the second half of the cycle. bg can be routed through a daisy-chained network or through a specific priority-encoded network. any method of external arbitration that observes the protocol can be used. 3.2.3 acknowledgment of mastership (three-wire bus arbitration only) upon receiving bg , the requesting device waits until as , dtack , and bgack are negated before asserting bgack . the negation of as indicates that the previous bus master has completed its cycle. (no device is allowed to assume bus mastership while as is asserted.) the negation of bgack indicates that the previous master has released the bus. the nega- tion of dtack indicates that the previous slave has terminated the connection to the previ- ous master. (in some applications, dtack might not be included in this function; general- purpose devices would be connected using as only.) when bgack is asserted, the assert- ing device is bus master until it negates bgack . bgack should not be negated until after the bus cycle(s) is complete. a device relinquishes control of the bus by negating bgack . the br from the granted device should be negated after bgack is asserted. if another bus request is pending, bg is reasserted within a few clocks, as described in section 3.3 bus arbitration control . the processor does not perform any external bus cycles before reas- serting bg .
bus operation motorola mc68307 user? manual 3-19 3.3 bus arbitration control all asynchronous bus arbitration signals to the processor are synchronized before being used internally. as shown in figure 3-18, synchronization requires a maximum of one and a half cycles of the system clock. the input asynchronous signal is sampled on the falling edge of the clock and is valid internally after the next rising edge. bus arbitration control is implemented with a finite state machine (see figure 3-19). in figure 3-19, input signals r and a are the internally synchronized versions of br and bgack . the bg output is shown as g, and the internal three-state control signal is shown as t. if t is true, the address, data, and control buses are placed in the high-impedance state when as is negated. all signals are shown in positive logic (active high), regardless of their true active voltage level. state changes (valid outputs) occur on the next rising edge of the clock after the internal signal is valid. a timing diagram of the bus arbitration sequence during a processor bus cycle is shown in figure 3-20. the bus arbitration timing while the bus is inactive (e.g., the processor is per- forming internal operations for a multiply instruction) is shown in figure 3-21. when a bus request is made after the mpu has begun a bus cycle and before as has been asserted (s0), the special sequence shown in figure 3-22 applies. instead of being asserted on the next rising edge of clock, bg is delayed until the second rising edge following its inter- nal assertion. figure 3-20, figure 3-21, and figure 3-22 apply to processors using three-wire bus arbitra- tion. figure 3-23, figure 3-24, and figure 3-25 apply to processors using two-wire bus arbitration. figure 3-18. external asynchronous signal synchronization clk br (external) br (internal) 47 internal signal valid external signal sampled
bus operation 3-20 mc68307 user? manual motorola figure 3-19. bus arbitration unit state diagrams r = bus request internal a = bus grant acknowledge internal g = bus grant t = three-state control to bus control logic x = don't care 1. state machine will not change if the bus is s0 or s1. 2. the address bus will be placed in the high-impedance state if t is asserted and as is negated. ra xx ra ra ra xx r + a xa r a rx 1 1 r r r x r x r r (a) three-wire bus arbitration (b) two-wire bus arbitration gt gt gt gt ra ra ra ra xa ra gt ra gt gt gt gt gt gt gt state 1 state 0 state 4 state 2 state 3
bus operation motorola mc68307 user? manual 3-21 figure 3-20. three-wire bus arbitration timing diagram?rocessor active s0 s1 s2 s3 s4 s5 s6 s7 s0 s1 s2 s3 s4 s5 s6 s7 s0 s1 clk bus three-stated bg asserted br valid internal br sampled br asserted bus released from three state and processor starts next bus cycle bgack negated internal bgack sampled bgack negated br bg bgack a23?0 as uds lds r/w dtack d15?0 processor alternate bus master processor
bus operation 3-22 mc68307 user? manual motorola figure 3-21. three-wire bus arbitration timing diagram?us inactive s0 s1 s2 s3 s4 s5 s6 s7 s0 s1 s2 s3 s4 clk bgack negated bg asserted and bus three stated br valid internal br sampled br asserted br bg bgack a23?0 as uds lds r/w dtack d15?0 bus released from three state and processor starts next bus cycle processor processor bus inactive alternate bus master
bus operation motorola mc68307 user? manual 3-23 figure 3-22. three-wire bus arbitration timing diagram?pecial case bus three-stated bg asserted br valid internal br sampled br asserted bus released from three state and processor starts next bus cycle bgack negated internal bgack sampled bgack negated br bg bgack as uds lds r/w dtack d15?0 s0 s2 s4 s6 s0 s2 s4 s6 s0 clk a23?0 processor alternate bus master processor
bus operation 3-24 mc68307 user? manual motorola figure 3-23. two-wire bus arbitration timing diagram?rocessor active s0 s1 s2 s3 s4 s5 s6 s7 s0 s1 s2 s3 s4 s5 s6 s7 s0 s1 clk bus three-stated bg asserted br valid internal br sampled br asserted bus released from three state and processor starts next bus cycle br negated internal br sampled br negated br bg bgack a23?0 as uds lds r/w dtack d15?0 processor alternate bus master processor
bus operation motorola mc68307 user? manual 3-25 figure 3-24. two-wire bus arbitration timing diagram?us inactive s0 s1 s2 s3 s4 s5 s6 s7 s0 s1 s2 s3 s4 clk br negated bg asserted and bus three stated br valid internal br sampled br asserted br bg bgack a23?0 as uds lds r/w dtack d15?0 bus released from three state and processor starts next bus cycle processor processor bus inactive alternate bus master
bus operation 3-26 mc68307 user? manual motorola figure 3-25. two-wire bus arbitration timing diagram?pecial case bus three-stated bg asserted br valid internal br sampled br asserted bus released from three state and processor starts next bus cycle br negated internal br sampled br negated br bg bgack as uds lds r/w dtack d15?0 s0 s2 s4 s6 s0 s2 s4 s6 s0 clk a23?0 processor alternate bus master processor
bus operation motorola mc68307 user? manual 3-27 3.4 bus error and halt operation in a bus architecture that requires a handshake from an external device, such as the asyn- chronous bus used in the m68000 family, the handshake may not always occur. a bus mon- itor is provided to terminate a bus cycle in error when the expected signal is not asserted. different systems and different devices within the same system require different maximum- response times. this internal circuitry asserts the internal ec000 core bus error signal after the appropriate delay following the assertion of address strobe. 3.4.1 bus error operation when the bus error condition is recognized, the current bus cycle is terminated in s7 for a read cycle, a write cycle, or the read portion of a read-modify-write cycle. for the write por- tion of a read-modify-write cycle, the current bus cycle is terminated in s19. after the aborted bus cycle is terminated, the processor enters exception processing for the bus error exception. during the exception processing sequence, the following information is placed on the supervisor stack: 1. status register 2. program counter (two words, which may be up to five words past the instruction being executed) 3. error information the first two items are identical to the information stacked by any other exception. the ec000 core stacks bus error information to help determine and to correct the error. after the processor has placed the required information on the stack, the bus error exception vector is read from vector table entry 2 (offset $08) and placed in the program counter. the processor resumes execution at the address in the vector, which is the first instruction in the bus error handler routine. refer to figure 3-26 for an example bus error timing diagram.
bus operation 3-28 mc68307 user? manual motorola figure 3-26. bus error timing diagram s0 s2 s4 s6 clk a23?0 ww w w s8 as lds/uds r/w dtack d15?0 berr halt initiate bus error detection initiate bus error stacking response failure read (internal)
bus operation motorola mc68307 user? manual 3-29 3.4.2 retrying the bus cycle if the internal bus error signal is asserted during a bus cycle in which halt is asserted by an external device, the ec000 core will initiate a retry operation. figure 3-27 is a timing dia- gram of the retry operation. the ec000 core terminates the bus cycle, then puts the data bus in the high-impedance state. the processor remains in this state until halt is negated. then the processor retries the preceding cycle using the same function codes, address, and data (for a write opera- tion). berr should be negated at least one clock cycle before halt is negated. notes there is no external connection to berr ; hence, users can not normally initiate a retry operation. the internal bus error is as- serted whenever a write protect violation, address decode con- flict, or hardware watchdog timeout occurs (assuming the offending condition is enabled in the scr). to guarantee that the entire read-modify-write cycle runs cor- rectly and that the write portion of the operation is performed without negating the address strobe, the processor does not re- try a read-modify-write cycle. when berr is asserted during a read-modify-write operation, a bus error operation is performed whether or not halt is asserted. figure 3-27. retry bus cycle timing diagram s0 s2 s4 s6 clk a23?1 s8 s0 s2 s4 s6 as lds/uds r/w dtack d15?0 berr (internal) halt 1 clock period 3 read halt retry
bus operation 3-30 mc68307 user? manual motorola 3.4.3 halt operation halt performs a halt/run/single-step operation. when halt is asserted by an external device, the processor halts and remains halted as long as the signal remains asserted, as shown in figure 3-28. while the processor is halted, bus arbitration is performed as usual. note if halt is asserted while a reset instruction is being executed, the cpu is reset. the single-step mode is derived from correctly timed transitions of halt . halt is negated to allow the processor to begin a bus cycle, then asserted to enter the halt mode when the cycle completes. the single-step mode proceeds through a program one bus cycle at a time for debugging purposes. the halt operation and the hardware trace capability allow tracing of either bus cycles or instructions one at a time. these capabilities and a software debug- ging package provide total debugging flexibility. figure 3-28. halt operation timing diagram s0 s2 s4 s6 clk a23?0 s0 s2 s4 s6 as r/w dtack d15?0 halt lds/uds read halt read
bus operation motorola mc68307 user? manual 3-31 3.4.4 double bus fault when a bus error exception occurs, the processor begins exception processing by stacking information on the supervisor stack. if another bus error occurs during exception processing (i.e., before execution of another instruction begins) the processor halts and asserts halt . this is called a double bus fault. only an external reset operation or a software watchdog timeout can restart a processor halted due to a double bus fault. a double bus fault occurs during a reset operation when a bus error occurs while the pro- cessor is reading the vector table (before the first instruction is executed). the reset opera- tion is described in the following paragraphs. 3.5 reset operation reset can be asserted externally for the initial processor reset. subsequently, the signal can be asserted either externally or internally (executing a reset instruction). for proper external reset operation, halt must also be asserted. the reset and halt bidirectional pins represent the standard m68000 method of reset. the mc68307 adds a master reset input (rstin ) which resets the mc68307. rstin gen- erates a reset , causing external devices in the system to be reset; note that halt is not asserted. at initial power-on, the mc68307? power-on reset asserts reset and halt internally until v dd reaches a minimum level. they are then held asserted for 32768 extal clocks, to ensure that the clock source has time to stabilize. subsequent assertions of rstin also incur a 32768 clock hold after the negating edge, which equates to 2ms for a 16.667 mhz system clock. because of this debouncing effect, this input is often used in preference to reset and halt when a reset switch is required. after the processor is reset, it reads the reset vector table entry (address $00000) and loads the contents into the supervisor stack pointer (ssp). next, the processor loads the contents of address $00004 (vector table entry 1) into the program counter. then the processor ini- tializes the interrupt level in the status register to a value of seven. no other register is affected by the reset sequence. figure 3-29 shows the timing of the reset operation.
bus operation 3-32 mc68307 user? manual motorola the active-low reset signal is asserted by the ec000 core when a reset instruction is executed. this signal should reset all external devices and internal peripherals (the ec000 core itself is not affected). the processor drives reset for 124 clock periods. to guarantee a reset of the core during this time, internal logic will stretch any reset or halt assertion to 132 clocks. 3.6 asynchronous operation to achieve clock frequency independence at a system level, the bus can be operated in an asynchronous manner. asynchronous bus operation uses the bus handshake signals to control the transfer of data. the handshake signals are as , uds , lds , dtack , the internal berr , and halt . as indicates the start of the bus cycle, and uds and lds signal valid data for a write cycle. after placing the requested data on the data bus (read cycle) or latch- ing the data (write cycle), the slave device (memory or peripheral) or the internal wait-state generator asserts dtack to terminate the bus cycle. if no device responds or if the access is invalid, internal control logic asserts the internal berr , to abort the cycle. figure 3-31 shows the use of the bus handshake signals in a fully asynchronous read cycle. figure 3- 30 shows a fully asynchronous write cycle. in the asynchronous mode, the accessed device operates independently of the frequency and phase of the system clock. for example, the mc68681 dual universal asynchronous receiver/transmitter (duart) does not require any clock-related information from the bus master during a bus transfer. asynchronous devices are designed to operate correctly with processors at any clock frequency when relevant timing requirements are observed. a device can use a clock at the same frequency as the system clock, but without a defined phase relationship to the system clock. this mode of operation is pseudo-asynchronous; it figure 3-29. power-on reset operation timing diagram t 4 clocks 23 4 5 6 notes: 1. internal start-up time 2. ssp high read in here 3. ssp low read in here 4. pc high read in here 5. pc low read in here 6. first instruction fetched here bus state unknown: all control signals inactive. data bus in read mode: clk + 3 volts v dd reset halt b us signals < t > 32768 clocks 1
bus operation motorola mc68307 user? manual 3-33 increases performance by observing timing parameters related to the system clock fre- quency without being completely synchronous with that clock. a memory array designed to operate with a particular frequency processor but not driven by the processor clock is a com- mon example of a pseudo-asynchronous device. the designer of a fully asynchronous system can make no assumptions about address setup time, which could be used to improve performance. with the system clock frequency known, the slave device can be designed to decode the address bus before recognizing an address strobe. parameter #11 (refer to section 11.7 ac electrical specifications?ead and write cycles (vcc = 5.0v 0.5v or 3.3vdc 0.3v; gnd = 0vdc; ta = tl to th) (see figure 11-3 and figure 11-4) ) specifies the minimum time before address strobe dur- ing which the address is valid. in a pseudo-asynchronous system, timing specifications allow dtack to be asserted for a read cycle before the data from a slave device is valid. the length of time that dtack may precede data is specified as parameter #31. this parameter must be met to ensure the valid- ity of the data latched into the processor. no maximum time is specified from the assertion of as to the assertion of dtack . during this unlimited time, the processor inserts wait cycles in one-clock-period increments until dtack is recognized. figure 3-33 shows the important timing parameters for a pseudo-asynchronous read cycle. during a write cycle, after the processor asserts as but before driving the data bus, the pro- cessor drives r/w low. parameter #55 specifies the minimum time between the transition figure 3-30. fully asynchronous write cycle figure 3-31. fully asynchronous read cycle addr as r/w uds/lds data dtack addr as r/w u ds /lds data dtack as r/w dtack uds/lds data addr addr as r/w u ds /lds data dtack
bus operation 3-34 mc68307 user? manual motorola of r/w and the driving of the data bus, which is effectively the maximum turnoff time for any device driving the data bus. after the processor places valid data on the bus, it asserts the data strobe signal(s). a data setup time, similar to the address setup time previously discussed, can be used to improve performance. parameter #26 is the minimum time a slave device can accept valid data before recognizing a data strobe. the slave device asserts dtack after it accepts the data. parameter #25 is the minimum time after negation of the strobes during which the valid data remains on the address bus. parameter #28 is the maximum time between the negation of the strobes by the processor and the negation of dtack by the slave device. if dtack remains asserted past the time specified by parameter #28, the processor may recognize it as being asserted early in the next bus cycle and may terminate that cycle prematurely. fig- ure 3-33 shows the important timing specifications for a pseudo-asynchronous write cycle. figure 3-32. pseudo-asynchronous read cycle addr as r/w uds/lds data dtack 11 17 a 31 28 29 addr as r/w uds /lds data dtack
bus operation motorola mc68307 user? manual 3-35 figure 3-33. pseudo-asynchronous write cycle addr as r/w uds/lds data dtack 11 55 22 26 28 29 20a c addr as r/w uds /lds data dtack
bus operation 3-36 mc68307 user? manual motorola 3.7 synchronous operation in some systems, external devices use the system clock to generate dtack and other asynchronous input signals. this synchronous operation provides a closely coupled design with maximum performance, appropriate for frequently accessed parts of the system. for example, memory can operate in the synchronous mode, but peripheral devices operate asynchronously. for a synchronous device, the designer uses explicit timing information shown in section 11.7 ac electrical specifications?ead and write cycles (vcc = 5.0v 0.5v or 3.3vdc 0.3v; gnd = 0vdc; ta = tl to th) (see figure 11-3 and figure 11-4) . these specifications define the state of all bus signals relative to a specific state of the processor clock. the standard m68000 bus cycle consists of four clock periods (eight bus cycle states) and, optionally, an integral number of clock cycles inserted as wait states. wait states are inserted as required to allow sufficient response time for the external device. the following state-by-state description of the bus cycle differs from those descriptions in section 3.1.2 16-bit m68000 bus read cycle and section 3.1.3 16-bit m68000 bus write cycle by including information about the important timing parameters that apply in the bus cycle states. state 0 the bus cycle starts in s0, during which the clock is high. at the rising edge of s0, the function code for the access is driven externally. parameter #6a defines the delay from this rising edge until the function codes are valid. also, the r/w signal is driven high; parameter #18 defines the delay from the same rising edge to the transition of r/w . the minimum value for parameter #18 applies to a read cycle preceded by a write cycle; this value is the maximum hold time for a low on r/w beyond the initiation of the read cycle. state 1 entering s1, a low period of the clock, the address of the accessed device is driven externally with an assertion delay defined by parameter #6. state 2 on the rising edge of s2, a high period of the clock, as is asserted. during a read cycle, uds and/or lds is also asserted at this time. parameter #9 defines the assertion delay for these signals. for a write cycle, the r/w signal is driven low with a delay defined by parameter #20. state 3 on the falling edge of the clock entering s3, the data bus is driven out of the high-impedance state with the data being written to the accessed device (in a write cycle). parameter #23 specifies the data assertion delay. in a read cycle, no signal is altered in s3. state 4 entering the high clock period of s4, uds /lds is asserted (during a write cycle) on the rising edge of the clock. as in s2 for a read cycle, parameter #9 defines the assertion delay from the rising edge of s4 for uds /lds . in a read cycle, no signal is altered by the processor during s4. until the falling edge of the clock at the end of s4 (beginning of s5), no response from any external device except reset is acknowledged by the
bus operation 3-37 mc68307 user? manual motorola processor. if dtack is asserted before the falling edge of s4 and satisfies the input setup time defined by parameter #47, the processor enters s5 and the bus cycle continues. if dtack is asserted but without meeting the setup time defined by parameter #47, the processor may recognize the signal and continue the bus cycle; the result is unpredictable. if dtack is not asserted before the next rise of clock, the bus cycle remains in s4, and wait states (complete clock cycles) are inserted until one of the bus cycle terminations is met. dtack is normally generated by the internal wait-state generator. state 5 s5 is a low period of the clock, during which the processor does not alter any signal. state 6 s6 is a high period of the clock, during which data for a read operation is set up relative to the falling edge (entering s7). parameter #27 defines the minimum period by which the data must precede the falling edge. for a write operation, the processor changes no signal during s6. state 7 on the falling edge of the clock entering s7, the processor latches data and negates as and uds /lds during a read cycle. the hold time for these strobes from this falling edge is specified by parameter #12. the hold time for data relative to the negation of as and uds /lds is specified by parameter #29. for a write cycle, only as and uds /lds , are negated; timing parameter #12 also applies. on the rising edge of the clock, at the end of s7 (which may be the start of s0 for the next bus cycle), the processor places the address bus in the high- impedance state. during a write cycle, the processor also places the data bus in the high-impedance state and drives r/w high. external logic circuitry should respond to the negation of the as and uds /lds by negating dtack , if it was asserted externally. parameter #28 is the hold time for dtack . figure 3-34 shows a synchronous read cycle and the important timing parameters that apply. the timing for a synchronous read cycle, including relevant timing parameters, is shown in figure 3-35. a key consideration when designing in a synchronous environment is the timing for the assertion of dtack by an external device. to properly use external inputs, the processor must synchronize these signals to the internal clock. the processor must sample the exter- nal signal, which has no defined phase relationship to the cpu clock, which may be chang- ing at sampling time, and must determine whether to consider the signal high or low during the succeeding clock period. successful synchronization requires that the internal machine receives a valid logic level, whether the input is high, low, or in transition. parameter #47 of section 11.7 ac electrical specifications?ead and write cycles (vcc = 5.0v 0.5v or 3.3vdc 0.3v; gnd = 0vdc; ta = tl to th) (see figure 11-3 and figure 11-4) is the asynchronous input setup time. signals that meet parameter #47 are guaranteed to be recognized at the next falling edge of the system clock. however, signals that do not meet parameter #47 are not guaranteed to be recognized. in addition, if dtack
bus operation 3-38 mc68307 user? manual motorola is recognized on a falling edge, valid data is latched into the processor (during a read cycle) on the next falling edge, provided the data meets the setup time required (parameter #27). when parameter #27 has been met, parameter #31 may be ignored. if dtack is asserted with the required setup time before the falling edge of s4, no wait states are incurred, and the bus cycle runs at its maximum speed of four clock periods. figure 3-34. synchronous read cycle figure 3-35. synchronous write cycle addr uds/lds r/w as clock dtack 6 9 s0 s1 s2 s3 s4 s5 s6 s7 s0 18 47 27 data addr as uds /lds r/w data dtack clock addr uds/lds r/w as clock dtack 6 s0 s1 s2 s3 s4 s5 s6 s7 s0 18 data 23 53 47 9 addr as uds /lds r/w data dtack clock
motorola mc68307 user? manual 4-1 section 4 ec000 core processor the ec000 core has a 16-bit data bus and 32-bit address bus while the full architecture pro- vides for 32-bit address and data register operations. 4.1 features the following resources are available to the ec000 core: eight 32-bit address registers eight 32-bit data registers 56 powerful instructions operations on five main data types memory-mapped input/output (i/o) 14 addressing modes 4.2 processing states the processor is always in one of three states: normal processing, exception processing, or halted. it is in the normal processing state when executing instructions, fetching instructions and operands, and storing instruction results. exception processing is the transition from program processing to system, interrupt, and exception handling. exception processing includes fetching the exception vector, stacking operations, and refilling the instruction pipe after an exception. the processor enters excep- tion processing when an exceptional internal condition arises such as tracing an instruction, an instruction results in a trap, or executing specific instructions. external conditions, such as interrupts and access errors, also cause exceptions. exception processing ends when the first instruction of the exception handler begins to execute. the processor halts when it receives an access error or generates an address error while in the exception processing state. for example, if during exception processing of one access error another access error occurs, the processor is unable to complete the transition to nor- mal processing and cannot save the internal state of the machine. the processor assumes that the system is not operational and halts. only an external reset can restart a halted pro- cessor. note that when the processor executes a stop instruction, it is in a special type of normal processing state, one without bus cycles. the processor stops, but it does not halt. thi d t t d ith f m k 4 0 4
ec000 core processor 4-2 mc68307 user? manual motorola 4.3 programming model the ec000 core executes instructions in one of two modes?ser mode or supervisor mode. the user mode provides the execution environment for the majority of application programs. the supervisor mode, which allows some additional instructions and privileges, is used by the operating system and other system software. to provide upward compatibility of code written for a specific implementation of the ec000 core, the user programmer's model, illustrated in figure 4-1, is common to all implementa- tions. in the user programmer's model, the ec000 core offers 16, 32-bit, general-purpose registers (d7?0, a7?0), a 32-bit program counter, and an 8-bit condition code register. the first eight registers (d7?0) are used as data registers for byte (8-bit), word (16-bit), and long-word (32-bit) operations. the second set of seven registers (a6?0) and the user stack pointer (usp) can be used as software stack pointers and base address registers. in addi- tion, the address registers can be used for word and long-word operations. all of the 16 reg- isters can be used as index registers. the supervisor programmer's model consists of supplementary registers used in the supervisor mode. the status register, illustrated in figure 4-2, contains the interrupt mask (eight levels avail- able) and the following condition codes: overflow (v), zero (z), negative (n), carry (c), and extend (x). additional status bits indicate that the processor is in the trace (t) mode and/or in the supervisor (s) state. figure 4-1. programming model supervisor programming model user programming model ccr pc a7/usp a6 a5 a4 a3 a2 a1 a0 d7 d6 d5 d4 d3 d2 d1 d0 31 0 31 0 ssp sr (ccr) program counter condition code register supervisor stack pointer status register (ccr is also shown in the user programming model) user stack pointer data registers address registers
ec000 core processor motorola mc68307 user? manual 4-3 4.3.1 data format summary the processor supports the basic data formats of the m68000 family. the instruction set supports operations on other data formats such as memory addresses. the operand data formats supported by the integer unit (iu) are the standard twos- complement data formats defined in the m68000 family architecture. registers, memory, or instructions themselves can contain iu operands. the operand size for each instruction is either explicitly encoded in the instruction or implicitly defined by the instruction operation. table 4-1 lists the data formats for the processor. refer to m68000pm/ad, m68000 family programmer? reference manual, for details on data format organization in registers and memory. 4.3.2 addressing capabilities summary the ec000 core supports the basic addressing modes of the m68000 family. the register indirect addressing modes support postincrement, predecrement, offset, and indexing, which are particularly useful for handling data structures common to sophisticated applica- tions and high-level languages. the program counter indirect mode also has indexing and offset capabilities. this addressing mode is typically required to support position-indepen- dent software. besides these addressing modes, the processor provides index sizing and scaling features. figure 4-2. status register table 4-1. processor data formats operand data format size notes bit 1 bit binary-coded decimal (bcd) 8 bits packed: 2 digits/byte; unpacked: 1 digit/byte byte integer 8 bits word integer 16 bits long-word integer 32 bits t0 s0 0i2i1i0 xnzvc 000 system byte user byte (condition code register) trace mode interrupt priority mask supervisor/user state extend negative zero overflow carry 15 14 13 12 11 10 9 8 7 5 6 43210
ec000 core processor 4-4 mc68307 user? manual motorola an instruction? addressing mode can specify the value of an operand, a register containing the operand, or how to derive the effective address of an operand in memory. each address- ing mode has an assembler syntax. some instructions imply the addressing mode for an operand. these instructions include the appropriate fields for operands that use only one addressing mode. table 4-2 lists a summary of the effective addressing modes for the pro- cessor. refer to m68000pm/ad, m68000 family programmer? reference manual, for details on instruction format and addressing modes. 4.3.3 notation conventions table 4-3 lists the notation conventions used in this manual unless otherwise specified. table 4-2. effective addressing modes addressing modes syntax register direct addressing data register direct address register direct ea = dn ea = an absolute data addressing absolute short absolute long ea = (next word) ea = (next two words) program counter relative addressing relative with offset relative with index and offset ea = (pc)+d 16 ea = (pc)+d 8 register indirect addressing register indirect postincrement register indirect predecrement register indirect register indirect with offset indexed register indirect with offset ea = (an) ea = (an), an an+n an an?, ea = (an) ea = (an)+d 16 ea = (an)+(xn)+d 8 immediate data addressing immediate quick immediate data = next word(s) inherent data implied addressing implied register ea = sr, usp, ssp, pc table 4-3. notation conventions single and double operand operations + arithmetic addition or postincrement indicator. arithmetic subtraction or predecrement indicator. arithmetic multiplication. arithmetic division or conjunction symbol. ~ invert; operand is logically complemented. l logical and v logical or logical exclusive or source operand is moved to destination operand. two operands are exchanged. any double-operand operation. tested operand is compared to zero and the condition codes are set appropriately. sign-extended all bits of the upper portion are made equal to the high-order bit of the lower portion. other operations trap equivalent to format offset word (ssp); ssp ?2 ssp; pc (ssp); ssp ?4 ssp; sr (ssp); ssp ?2 ssp; (vector) pc stop enter the stopped state, waiting for interrupts. 10 the operand is bcd; operations are performed in decimal.
ec000 core processor motorola mc68307 user? manual 4-5 if then else test the condition. if true, the operations after ?hen?are performed. if the condition is false and the optional ?lse?clause is present, the operations after ?lse?are performed. if the condition is false and else is omitted, the instruction performs no operation. refer to the bcc instruction de- scription as an example. register specification an any address register n (example: a3 is address register 3) ax, ay source and destination address registers, respectively. br base register?n, pc, or suppressed. dc data register d7?0, used during compare. dh, dl data registers high- or low-order 32 bits of product. dn any data register n (example: d5 is data register 5) dr, dq data register? remainder or quotient of divide. du data register d7?0, used during update. dx, dy source and destination data registers, respectively. rn any address or data register rx, ry any source and destination registers, respectively. xn index register?n, dn, or suppressed. data format and type operand data format: byte (b), word (w), long (l), or packed (p). b, w, l specifies a signed integer data type (twos complement) of byte, word, or long word. k a twos complement signed integer (?4 to +17) specifying a number? format to be stored in the packed decimal format. subfields and qualifiers # or # immediate data following the instruction word(s). ( ) identifies an indirect address in a register. [ ] identifies an indirect address in memory. bd base displacement d n displacement value, n bits wide (example: d 16 is a 16-bit displacement). lsb least significant bit lsw least significant word msb most significant bit msw most significant word od outer displacement scale a scale factor (1, 2, 4, or 8, for no-word, word, long-word, or quad-word scaling, respectively). size the index register? size (w for word, l for long word). {offset:width} bit field selection. register names ccr condition code register (lower byte of status register) pc program counter sr status register register codes * general case. c carry bit in ccr cc condition codes from ccr fc function code n negative bit in ccr u undefined, reserved for motorola use. v overflow bit in ccr x extend bit in ccr z zero bit in ccr not affected or applicable. table 4-3. notation conventions (continued)
ec000 core processor 4-6 mc68307 user? manual motorola 4.4 ec000 core instruction set overview design of the instruction set gives special emphasis to support of structured, high-level lan- guages and to ease of assembly language programming. each instruction, with a few excep- tions, operates on bytes, words, and long words, and most instructions can use any of the 14 addressing modes. over 1000 useful instructions are provided by combining instruction types, data types, and addressing modes. these instructions include signed and unsigned multiply and divide, ?uick?arithmetic operations, bcd arithmetic, and expanded operations (through traps). additionally, the highly symmetric, proprietary microcoded structure of the instruction set provides a sound, flexible base for the future. the ec000 core instruction set is listed in table 4-4. for detailed information on the ec000 core instruction set, refer to m68000pm/ad, m68000 family programmer's reference man- ual . stack pointers sp active stack pointer ssp supervisor stack pointer usp user stack pointer miscellaneous effective address


▲Up To Search▲   

 
Price & Availability of MC68307FG16

All Rights Reserved © IC-ON-LINE 2003 - 2022  

[Add Bookmark] [Contact Us] [Link exchange] [Privacy policy]
Mirror Sites :  [www.datasheet.hk]   [www.maxim4u.com]  [www.ic-on-line.cn] [www.ic-on-line.com] [www.ic-on-line.net] [www.alldatasheet.com.cn] [www.gdcy.com]  [www.gdcy.net]


 . . . . .
  We use cookies to deliver the best possible web experience and assist with our advertising efforts. By continuing to use this site, you consent to the use of cookies. For more information on cookies, please take a look at our Privacy Policy. X